Rebooting/Halting system from kernel module
geoffrey levand
geoffrey.levand at mail.ru
Sun Jan 22 17:38:53 UTC 2012
Thanks.
shutdown_nice is working great.
regards
22 января 2012, 21:07 от Ian Lepore <freebsd at damnhippie.dyndns.org>:
> On Sun, 2012-01-22 at 14:19 +0400, geoffrey levand wrote:
> > Hi,
> >
> > how would i reboot/halt the system from a kernel module ?
> >
> > regards
> >
> > --
> > Почта@Mail.Ru в твоем мобильном!
> > Просто зайди с телефона на m.mail.ru
>
> There is an undocumented (at least in terms of a manpage) function named
> shutdown_nice() in sys/kern/kern_shutdown.c that will send a signal to
> the init process if it's running or call boot(9) if not. Or maybe a
> direct call to boot(9) is what you're looking for, if bypassing the
> running of rc shutdown scripts and all is your goal. (There is a mapage
> for boot(9)).
>
> -- Ian
>
>
More information about the freebsd-hackers
mailing list