Remotely shutdown multiple PCs via script
Frank Elsner
frank at moltke28.B.Shuttle.DE
Fri Dec 9 19:38:28 UTC 2011
On Fri, 9 Dec 2011 14:16:00 -0500 (EST) Alan Stern wrote:
> On Fri, 9 Dec 2011, Doug Kuvaas wrote:
>
> > Here is what I am trying to do:
> >
> > >From a central server running HP-UX, I would like to shutdown multiple
> > Fedora PCs using a script. This in itself is not a problem. I have an
> > account on the machines added to the sudoers file to allow them to shut
> > down the systems, and connect to said systems using ssh. I can get the
> > systems to shut down remotely using the command ssh -t user at host "sudo
> > /sbin/shutdown -h now". If I run the script on the host computer it works
> > like I would expect.
> >
> > The problem I am running into is the host computer is typically accessed
> > through one of the Fedora PCs being used to shut it down. So when I run
> > the script, it gets to the point where it is telling the current computer
> > to shutdown, the script is terminated and no further systems shut down.
>
> > Anyone have any ideas?
>
> When invoking the script from one of the PCs, run it in the background
> (maybe with nohup) so that it doesn't get killed when the PC shuts
> down.
Whou! Programs started with nohup keep running after shutdown! Get real.
--Frank
More information about the users
mailing list