journalctl vacuum code example
Example 1: ubuntu cleanup systemd journal
$ journalctl --vacuum-time=10d
...
Vacuuming done, freed 2.3G of archived journals on disk.
Example 2: journalctl vacuum
journalctl --vacuum-size=50M
journalctl --vacuum-time=2d