Stop journald from dumping useless boot logs all over your disk

Logging & Journald

Stop journald from dumping useless boot logs all over your disk

🧩 The Challenge

Dealing with a server that’s been up for a year and finding out the journal is taking up 10 gigs of space is a classic Friday afternoon nightmare. Nobody needs to keep every single boot log from last July, but systemd loves to hoard them like a digital packrat.

💡 The Fix

You can cap the total disk space usage and limit how long those logs persist with a couple of quick settings in the config file. It saves your partitions from filling up and stops the system from wasting IO on logs you’ll never read.

sed -i 's/#SystemMaxUse=/SystemMaxUse=500M/' /etc/systemd/journald.conf
systemctl restart systemd-journald

⚙️ Why It Works

Tweaking these lines tells journald to strictly enforce a disk quota for logs, so it automatically rotates out the old data once the limit is hit. Since you’re editing the config directly, it persists across reboots unlike the runtime flags.

🚀 Pro-Tip: Run journalctl –disk-usage afterward to see how much space you actually reclaimed.

Linux Tips & Tricks | © ngelinux.com | 12/3/2026

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Newest
Oldest Most Voted