[systemd-devel] issuing 'reboot' command does not print the familiar 'Restarting system.' message

Daniel Mack daniel at zonque.org
Mon Apr 13 03:59:21 PDT 2015


On 04/12/2015 03:46 PM, Lennart Poettering wrote:
> On Fri, Apr 10, 2015 at 10:18 AM, Ani Sinha <ani at arista.com> wrote:

>> OK I see it now. shutdownd.c eventually issues 'shutdown -r now'. This
>> > gets parsed by shutdown_parse_argv(). Eventually we end up calling
>> > halt_main() ->halt_now() ->reboot(RB_AUTOBOOT).
> Hmm?
> 
> shutdownd's only raison d'etre is to support scheduled shutdowns. It's
> not used unless you actually use scheduled shutdowns. If you just use
> "systemctl poweroff" or so, then it will *not* be used at all, and is
> not involved at all in the shutdown logic.
> 
> And no! shutdownd will never call halt_main(), nor halt_now(), nor
> reboot(RB_AUTOBOUT). If you use shutdownd, then this will result in
> the equiavlent of "systemctl poweroff" and so on, just delayed a bit.
> 
> Please don't confuse shutdownd.c and shutdown.c. The former is just
> there for the scheduled shutdown bits, the latter is the always used
> last part of the shutdown logic.

Also note that shutdownd is one of the oldest pieces of code in the
systemd project. I'm currently working on patches to replace it entirely
with a DBus API in logind.


Thanks,
Daniel



More information about the systemd-devel mailing list