Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am running a Debian unstable with systemd, at boot I have a few services which are marked as FAILED (and not OK), but the log is too fast for me to grab the name of the failed service.

I wonder if there is a way to get this boot log once the system is up and running (I am NOT speaking about the kernel log which are reachable with dmesg but the services). And, the service --status-all does not really help because it only list the services that are on/off but not the one that have failed at boot.

So, any hint is welcome !

share|improve this question
3  
Try journalctl, then searching for the names of the failed services. There are also options to that command to filter on service name from the start. – Tom Hunt Oct 21 '15 at 21:28
up vote 2 down vote accepted

Try:

 systemctl --state=failed

man systemctl says:

--state=

The argument should be a comma-separated list of unit LOAD, SUB, or ACTIVE states. When listing units, show only those in specified states. Use --state=failed to show only failed units.

Run (as root):

systemctl status <service-name>

status [PATTERN...|PID...]]

Show terse runtime status information about one or more units, followed by most recent log data from the journal.

Also:

journalctl -u <service-name> -b
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.