0

May someone tell me if the system logs (especially dmesg) are archived somewhere else than /var/logs? In this folder I can find only dmesg from last 6 restarts. I need to look two weeks before to solve a problem.

in /etc/logrotate.conf i could see:

# rotate log files weekly
weekly

# keep 4 weeks worth of backlogs
rotate 4

How can it be, that on server distro i can not look into logs older than last few restarts, which I have performed in the last two days? Or did I miss something?

I'm using Lubuntu Server 19.10

  • Lubuntu is a desktop OS, have you installed lubuntu-desktop on your Ubuntu Server, or are you using Lubuntu desktop as if it's a server. – guiverc Feb 29 at 7:08
1

You do have the Systemd journal at you disposal. Read up on the 'journalctl' command to learn all about itman journalctl. To view a list of boot logs from journald in a terminal:

journalctl --list-boots

Current boot:

journalctl -b 0

Previous boot:

journalctl -b 1

three boots ago:

journalctl -b 3

and so on.

Messages from two weeks ago:

journalctl --since="2020-2-15 9:30:00"

by unit(or service):

journalctl -u sddm.service

And much more.

|improve this answer|||||
  • Thank you for your answer. It was very helpful and informative! I managed to solve my problem. – alex Feb 29 at 12:59

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.