[H-GEN] rebooting system
Benjamin
benjamincarlyle at optusnet.com.au
Fri Sep 19 11:31:12 EDT 2003
[ Humbug *General* list - semi-serious discussions about Humbug and ]
[ Unix-related topics. Posts from non-subscribed addresses will vanish. ]
Richard wrote:
> I access my linux box remotely only (no monitor, keyboard or mouse attached)
> and I was just wondering if there's a way to get my system to automatically
> reboot once a week (at some ungodly hour of the night when I should be in
> bed)? Even better, is it possible for it to only reboot if no one is using
> it?
If you want something done periodically, your best bet is cron. As root
type "crontab -e". See the cron and crontab man pages for more info.
Some trivial scripting should be able to check whether any users are
logged on before the automatic reboot.
As an aside, is there any particular reason you want to do this? It's
generally considered bad karma to reboot a unix machine just for the
hell of it ;) If there's a problem that you're trying to address,
perhaps it could be addressed in an alternative way.
Interestingly I've seen windows[1] used in some mission-critical
environments with a two machine main-backup combination. Of course the
windows machines could not run for long periods of time without running
into problems, so once a week the server currently controlling the
system was rebooted as a "failover test". The backup took control, the
main got its operating system's state refereshed to time 0, and the
system remained fairly reliable :)
Benjamin
[1] Typically quite old and well understood windows revisions
--
* This is list (humbug) general handled by majordomo at lists.humbug.org.au .
* Postings to this list are only accepted from subscribed addresses of
* lists 'general' or 'general-post'. See http://www.humbug.org.au/
More information about the General
mailing list