Re: Remotely rebooting a machine with state 'D' processes, how?

Kai Henningsen (kaih@khms.westfalen.de)
11 Aug 2001 13:28:00 +0200


torvalds@transmeta.com (Linus Torvalds) wrote on 10.08.01 in <200108102159.f7ALxb908284@penguin.transmeta.com>:

> In article <20010810231906.A21435@bonzo.nirvana> you write:
> >How can I reboot a stuck machine remotely, when there are uninterruptable
> >processes arround? shutdown -r, reboot [-n] [-f], telinit 6 do not give the
> >intended results. Localy I can use Alt-SysRq-S/U/B, but what if I still
> >have a remote ssh connection and don't want to have to get to the machines
> >location?
> >Of course the real problem are the processes themselves, but being able to
> >revive a machine is also nice ;)
>
> You have to use the reboot() system call directly as root, with the
> proper arguments to make it avoid doing even any sync. See
>
> man 2 reboot
>
> for details.

I thought that was exactly what reboot -n -f does: don't sync, don't call
shutdown, just reboot immediately. That's certainly what I have
(successfully) used that for in the past.

MfG Kai
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/