** Description changed:

  The directory size limits for systemd journal files are much too large.
  
  The rules woud work for a small[ish] partition dedicated to /var/log but
  when (as is usual) /var/log is on the main systm partition the size
  limits are too big.
  
  For example I have a system where the main disk is 1000Gb, /var/log is
  on this disk.  Thus the 10% limit for /var/log/journal would be 100Gb,
  the 4Gb absolute limit is therefore used but this is still far too big
  in my opinion.
+ 
+ 
+ ---
+ 
+ 
+ at the start of journald, it calculates dynamically the caps for persistent 
journal. And it tries hard to not breach them, as in it does vacuum and rotate 
them, when the max thresholds are reached.
+ 
+ You can inspect the journald sizes using
+ 
+ $ journalctl -u systemd-journald | grep -e 'Runtime journal' -e 'System
+ journal'
+ 
+ On my system i have it as:
+ Nov 05 10:57:26 ottawa systemd-journald[560]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
+ Nov 05 10:57:26 ottawa systemd-journald[560]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 4.1G, max 4.0G, 0B free.
+ Nov 05 12:54:45 ottawa systemd-journald[562]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
+ Nov 05 12:54:45 ottawa systemd-journald[562]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 3.9G, max 4.0G, 15.6M 
free.
+ Nov 05 14:03:40 ottawa systemd-journald[550]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
+ Nov 05 14:03:40 ottawa systemd-journald[550]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 3.9G, max 4.0G, 7.6M 
free.
+ 
+ You can see that it breached 4.0G limit by a rounding error, but then
+ got vacuumed down to 3.9G again.
+ 
+ If you dislike the default sizes, you can control them via journald.conf
+ configuration file and cmdline settings. For runtime journal it is
+ sensitive to the overall RAM available, and the mount options of /run,
+ which have defaults built into initramfs & systemd. Similarly for system
+ journal, total disk size also matters. Everything is controllable via
+ journald.conf as the final limits.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1785503

Title:
  systemd journal too large

Status in systemd package in Ubuntu:
  Won't Fix

Bug description:
  The directory size limits for systemd journal files are much too
  large.

  The rules woud work for a small[ish] partition dedicated to /var/log
  but when (as is usual) /var/log is on the main systm partition the
  size limits are too big.

  For example I have a system where the main disk is 1000Gb, /var/log is
  on this disk.  Thus the 10% limit for /var/log/journal would be 100Gb,
  the 4Gb absolute limit is therefore used but this is still far too big
  in my opinion.

  
  ---

  
  at the start of journald, it calculates dynamically the caps for persistent 
journal. And it tries hard to not breach them, as in it does vacuum and rotate 
them, when the max thresholds are reached.

  You can inspect the journald sizes using

  $ journalctl -u systemd-journald | grep -e 'Runtime journal' -e
  'System journal'

  On my system i have it as:
  Nov 05 10:57:26 ottawa systemd-journald[560]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
  Nov 05 10:57:26 ottawa systemd-journald[560]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 4.1G, max 4.0G, 0B free.
  Nov 05 12:54:45 ottawa systemd-journald[562]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
  Nov 05 12:54:45 ottawa systemd-journald[562]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 3.9G, max 4.0G, 15.6M 
free.
  Nov 05 14:03:40 ottawa systemd-journald[550]: Runtime journal 
(/run/log/journal/1b8df0fa27039f0163586c6756a6d401) is 8.0M, max 156.8M, 148.8M 
free.
  Nov 05 14:03:40 ottawa systemd-journald[550]: System journal 
(/var/log/journal/1b8df0fa27039f0163586c6756a6d401) is 3.9G, max 4.0G, 7.6M 
free.

  You can see that it breached 4.0G limit by a rounding error, but then
  got vacuumed down to 3.9G again.

  If you dislike the default sizes, you can control them via
  journald.conf configuration file and cmdline settings. For runtime
  journal it is sensitive to the overall RAM available, and the mount
  options of /run, which have defaults built into initramfs & systemd.
  Similarly for system journal, total disk size also matters. Everything
  is controllable via journald.conf as the final limits.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1785503/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to