About this article: This article is reviewed against the cited sources. This is source research, not lab validation. Check the stated versions and your own requirements before making changes.
When /var/log/journal is large, run journalctl --disk-usage to see what the journal holds. Trim it once with journalctl --vacuum-size= (or --vacuum-time=), then set SystemMaxUse= in a journald.conf drop-in so it stays small. Before you do either, confirm the journal really is the thing filling the disk, because vacuuming only removes archived journal files and nothing else.
What the symptom means
The systemd journal stores log entries in binary files. The journald manual says that data is kept below /var/log/journal when storage is persistent, and below /run/log/journal (memory) when it is volatile. The journald.conf manual says Storage= "Defaults to persistent in the default journal namespace (this value is determined at compilation time)", so the default is set when systemd is built. The journald manual says that by default log data is stored persistently if /var/log/journal/ exists during boot, "with an implicit fallback to volatile storage otherwise", and the auto value behaves the same way. To check your host, look for a Storage= line in the files named under "Prove the cause", and check whether the directory /var/log/journal exists.
journald limits its own size. According to the manual:
SystemMaxUse=caps how much disk the journal may use. It defaults to 10% of the file system, capped at 4G.SystemKeepFree=is how much space journald leaves free for other uses. It defaults to 15% of the file system, also capped at 4G.- journald "will respect both limits and use the smaller of the two values."
SystemMaxFileSize=defaults to one eighth ofSystemMaxUse=, capped at 128M, "so that usually seven rotated journal files are kept as history."
Two points in the manual matter after a vacuum. First, only archived files are deleted to reduce space, so "there might still be more space used than SystemMaxUse=" after a vacuum. Active files stay. Second, if the file system is already nearly full when journald starts, the limit is raised to the percentage that is actually free, and journald "will not be removing existing files to reduce the footprint again."
So a journal of a few gigabytes matches the defaults the manual describes. A full disk is a problem only when the limits are set too high, the journal sits on a small file system, or something else is the real consumer.
Likely causes
| Cause | What you see | How to confirm |
|---|---|---|
| Defaults on a small or crowded file system | Journal is a few GB, which is the default cap, but the file system is small | journalctl --disk-usage against the size of the file system holding /var |
| Limits raised in configuration | Journal grows far past 10% of the file system | Read /etc/systemd/journald.conf and its drop-in directories for SystemMaxUse= |
| One noisy service | One unit writes a large share of the entries, for example at debug level | journalctl -F _SYSTEMD_UNIT, then count entries per unit |
| Journal is not the consumer | journalctl --disk-usage is small but the disk is full |
du on /var/log, then the pages on inodes and deleted open files |
| Many archived files from long uptime | Dozens of journal files, oldest months old | journalctl --vacuum-time= removes by age |
Prove the cause before changing anything
These commands only read.
journalctl --disk-usage
The manual says this "shows the sum of the disk usage of all archived and active journal files." It does not give an output format, so read the figure it prints and compare it with the file system size.
du -xh --max-depth=1 /var/log
du -h prints human-readable sizes, -x stays on one file system and --max-depth=1 limits the listing to one level, as documented in the du manual. If /var/log/journal is not the largest entry, stop here. The journal is not your problem; read the pages titled "Linux Says No Space Left but Bytes Are Free: Check Inodes and Quotas" and "Files Deleted but Linux Disk Space Is Still Used: Find Open File References".
Next, check the configuration. journald reads /etc/systemd/journald.conf, then drop-ins from /etc/systemd/journald.conf.d/*.conf, /run/systemd/journald.conf.d/*.conf, /usr/local/lib/systemd/journald.conf.d/*.conf and /usr/lib/systemd/journald.conf.d/*.conf. Look for SystemMaxUse=, SystemKeepFree=, SystemMaxFileSize=, SystemMaxFiles= and Storage=. If none is set, the defaults above apply.
To find the noisy source, list the units that appear in the journal, then count entries for a suspect:
journalctl -F _SYSTEMD_UNIT
journalctl -u nginx.service --since today --no-pager | wc -l
-F or --field= prints "all possible data values the specified field can take in all entries of the journal." --since today and --no-pager are documented. Compare counts across the busiest units. Add -p err (priority filter) to see whether the volume is errors or routine messages.
You can also check the journal's own consistency with journalctl --verify, which the manual describes as checking "the journal file for internal consistency." It reads; it does not repair.
Example (illustrative): web01 has a 40 GiB file system holding /var. journalctl --disk-usage reports about 4 GiB. The defaults give SystemMaxUse= of 10% of 40 GiB = 4 GiB, which equals the 4G cap, and SystemKeepFree= of 15% of 40 GiB = 6 GiB, capped to 4 GiB. The journald manual says each calculated default is capped to 4G, and that journald uses the smaller of the two limits, so 4 GiB applies. The journal is behaving as the defaults describe. SystemMaxFileSize= would be 4 GiB ÷ 8 = 512 MiB, capped at 128M (the manual's seven rotated files apply when the one-eighth value is not capped), so about 4,096 MiB ÷ 128 MiB = 32 files. The administrator wants the journal near 1 GiB, so the plan is a one-off --vacuum-size=500M, then SystemMaxUse=1G in a drop-in.
Fix
One-off trim
journalctl --rotate --vacuum-size=500M
The manual says --vacuum-size= "removes the oldest archived journal files until the disk space they use falls below the specified size", accepting K, M, G and T suffixes (powers of 1024). It also says these switches "may also be combined with --rotate into one command", in which case "all active files are rotated first", so the vacuum can take all log data written so far into account. You can instead use --vacuum-time=2weeks to keep a time window, or --vacuum-files= to keep a number of files. A value of zero means no limit for that switch.
Disruptive step: vacuuming permanently deletes the oldest log entries, and journal files cannot be recovered afterwards unless you have a copy. Back out only by restoring from a backup of /var/log/journal. Copy anything you need for an investigation first. The journalctl manual says --rotate marks all currently active journal files as archived and renamed, so that they are never written to in future, and creates new empty files in their place. It does not say rotation is risk-free, and after it the older entries sit in archived files that a vacuum can delete.
Keep it small afterwards
Create a drop-in rather than editing the vendor file. The manual recommends prefixing drop-in names with two digits and a dash, and using the range 60-90 for files in /etc/.
File /etc/systemd/journald.conf.d/70-journal-size.conf:
[Journal]
SystemMaxUse=1G
Then apply it:
systemctl restart systemd-journald
Disruptive step: this restarts the logging service. The journald manual says "it is thus safe to restart systemd-journald.service, but stopping it is not recommended", because restarting through systemctl restart keeps the stdout and stderr stream connections of services open. Back out by deleting the drop-in and restarting again.
SystemMaxUse= is enforced "synchronously when journal files are extended", so no scheduled job is needed. Archived files are deleted as the limit is reached.
If one service is the cause
Fix the service first: lower its log level or correct the fault that logs on every request. As a backstop, journald rate-limits per service, with RateLimitIntervalSec= and RateLimitBurst= defaulting to 10000 messages in 30 seconds. The manual also describes MaxLevelStore=, whose default is debug; setting it to info or notice drops more verbose messages from the journal. Dropped messages are lost for good, so use it only for data you do not need.
If the journal is volatile and you want it persistent
The systemd-journald manual says that where persistent logging is wanted and /var/log/journal/ does not exist, "it is sufficient to create the directory", with mkdir -p /var/log/journal and systemd-tmpfiles --create --prefix /var/log/journal. Do this only if you have first set a limit, or the journal will begin to grow towards the default cap.
Risk: creating the directory changes where logs are kept: with Storage=auto the journal then behaves as persistent, writes to the disk that is under pressure, and grows towards the cap. Back out by setting Storage=volatile in a drop-in and restarting systemd-journald; the journald.conf manual says volatile keeps data only in memory, below /run/log/journal. The manual also says auto behaves as volatile when /var/log/journal does not exist, so removing the directory and restarting returns auto to volatile. Files already written to disk stay on disk until you vacuum them. Logs held only in memory are lost at reboot.
Confirm the fix
journalctl --disk-usageshows a figure at or near your limit.df -hon the file system shows the freed space. If space does not come back, check whether an open deleted file is holding it; see the page titled "Files Deleted but Linux Disk Space Is Still Used: Find Open File References".journalctl -u <unit> --since todaystill returns recent entries, so logging works.- After a day,
journalctl --disk-usagehas not climbed pastSystemMaxUse=. The manual notes the active files may let the total briefly exceed it.
What to watch afterwards
- The journal total against
SystemMaxUse=, and the file system's free percentage. - The unit with the highest entry count per day. A rising count points to a fault, not a retention problem.
- Whether you need longer retention for audit reasons.
MaxRetentionSec=defaults to 0, which turns time-based deletion off, andMaxFileSec=defaults to one month. - Any forwarding of logs to another system: the vacuum deletes local copies only.
Read next
Related articles you may want next.
- TroubleshootingLinux Says No Space Left but Bytes Are Free: Check Inodes and QuotasDistinguish inode exhaustion, quota limits and checking the wrong mount before any cleanup.Read article
- TroubleshootingFiles Deleted but Linux Disk Space Is Still Used: Find Open File ReferencesAttribute retained deleted files to exact processes and choose a supported reopen or controlled restart.Read article
- Troubleshooting/boot is full and the kernel update will not install: remove old kernels the safe wayKernel update fails, /boot is full? Check df, keep the running kernel, remove old kernels with apt or dnf, and fix the half-installed package.Read article
Risks and limits
- These commands have not been run or lab-tested. They are taken from the manual pages cited in Sources.
journalctl --disk-usagehas no output format in the manual, so none is shown here.- Vacuuming cannot reduce active files, so the figure may stay above your target until the next rotation.
- Deleting logs removes records you may need for an incident or an audit. Copy them first.
- The manuals read are marked "systemd 262". On an older systemd, check each option against your own
man journalctlandman journald.conf, because several options were added in later versions. - Settings in the kernel command line, journal namespaces and per-user journals are not covered here.
Sources
- journalctl(1) — systemd project, header "systemd 262", no date shown, accessed 18 November 2026
- journald.conf(5) — systemd project, header "systemd 262", no date shown, accessed 18 November 2026
- systemd-journald.service(8) — systemd project, no date shown, accessed 18 November 2026
- du(1) — GNU coreutils 9.11 (page obtained 2026-08-03), accessed 18 November 2026
- df(1) — GNU coreutils 9.11 (page obtained 2026-08-03), accessed 18 November 2026
This article was originally published on .