[systemd-devel] Fall back to shell and still see failure

Lennart Poettering lennart at poettering.net
Mon May 18 10:35:06 PDT 2015


On Mon, 18.05.15 13:23, Chris Morin (chris.morin2 at gmail.com) wrote:

> Hi
> 
>   During a normal boot on my system, the last service to launch starts
> a special shell which isn't your standard linux shell. Unfortunately,
> before getting to that service, there is a long chain of dependencies
> which have to run. I want to drop to a normal linux shell when any of
> these dependencies fail to be able to jump right into debugging it.
> 
> I set the "OnFailure" option of the last service to
> "emergency.target". This works great. The only issue is that the shell
> appears before systemd has a chance to display which service actually
> failed.
> 
>  I can obviously check which service failed with "systemctl --failed"
> but I'd like to have it displayed during boot as it normally is.
> 
> I'm assuming I can't see the failure message because emergency.service
> grabs control of the console before systemd can print out it's
> message. Is this the case? Is there any way to get what I'm looking
> for?

Type=idle is for cases like this. See systemd.service(5) for details.

Lennart

-- 
Lennart Poettering, Red Hat


More information about the systemd-devel mailing list