2

What should I look for in the systemd journal to find when the latest boot happened?

1
  • 2
    Read man journalctl, do sudo journalctl --list-boots, see my AskUbuntu profile (click on my username) for more journalctl hints.
    – waltinator
    Feb 11 at 20:38
3

I would use an empty -b,--boot option to journalctl in order to request "the current boot", then -n 0 to request zero lines of output, which leaves just the header:

journalctl -b -n 0

Example output:

-- Logs begin at Wed 2021-02-10 17:46:08 PST, end at Thu 2021-02-11 15:36:01 PST. --

Or if the -n 0 fails to output the proper information try the number 1.

~# journalctl -b -n 0
-- No entries --
~# journalctl -b -n 1
-- Logs begin at Mon 2021-02-08 20:24:14 AST, end at Thu 2021-02-11 21:33:56 AST. --
Feb 11 21:33:56 zeus-H370M systemd[1]: anacron.service: Succeeded.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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