[systemd-devel] MaxRetentionSec does not delete entries older than the specified time

Andrei Borzenkov arvidjaar at gmail.com
Sun May 29 11:24:29 UTC 2022


On 29.05.2022 12:04, baba wrote:
> In my /etc/systemd/journald.conf, I have:
> Storage=persistent
> MaxRetentionSec=3day
> 
> And it doesn't delete entries older that 3 days:
> 

Retention does not delete *entries*. It deletes archived journal files.

...

> 
> In this case is the journal daemon automatically archive active journal files or 
> I need to do it manually with the --rotate option?

In which case? Current active journal file gets archived when it is
full. Retention policies apply only to these archived files.

Of course you can force rotation manually if you need.


More information about the systemd-devel mailing list