Skip to Content.
Sympa Menu

internetworkers - Re: quick unix question

internetworkers AT lists.ibiblio.org

Subject: Internetworkers: http://www.ibiblio.org/internetworkers/

List archive

Chronological Thread  
  • From: "Michael D. Thomas" <mdthomas AT mindspring.com>
  • To: "InterNetWorkers" <internetworkers AT franklin.oit.unc.edu>
  • Subject: Re: quick unix question
  • Date: Mon, 1 Jul 2002 20:42:29 -0400



----- Original Message -----
From: "Steven Champeon" <schampeo AT hesketh.com>
To: "InterNetWorkers" <internetworkers AT franklin.oit.unc.edu>
Sent: Monday, July 01, 2002 7:25 PM
Subject: [internetworkers] Re: quick unix question


> on Mon, Jul 01, 2002 at 06:35:27PM -0400, Kate Johnson wrote:
> >
> > I need to reboot a server. What is the syntax to send a message to user
> > screens telling them to logoff now?
>
> If you do 'shutdown -h now' it will do a wall(1) saying something to
> that effect, anyway. But you can do a wall(1), a la:

[on linux. should be good for others.]

1) A message of your choosing can be passed to the shutdown command.
2) You'll want to use -r for rebooting.

This gives your users 5 minutes and the message "Hardware upgrade".

#/sbin/shutdown -r +5 Hardware upgrade

Of course, consult your local man page:

#man shutdown

I always end up reading it about 3 times because it seems all of my UNIX
reboots are of remote machines in other states/countries in the middle of the
night.













Archive powered by MHonArc 2.6.24.

Top of Page