Hello Lennart, Colin,
----- Original Message -----
From: Lennart Poettering <mzerqung(a)0pointer.de>
Subject: Re: logrotate(8) and copytruncate as default
The systemd-journald takes care of all of: receiving messages, writing
them to storage, and rotating the storage.
We do synchronous rotation before each write. i.e. the moment we append
to a file we check if the write would cause the disk usage to be out of
limits, and then do the rotation right away.
I see. While doing this rotation, I guess systemd uses flock(2) or similar
mechanism to pause writing to a log file, move/rename or copy-truncate that
file and continue writes again?
You can configure how much disk space journald should take up at
max,
and how much you want to remain free.
You can also configure a time limit, to enforce that everything older
than a certain time is always cleaned up (though this is really
something for weird data retention policy setups, normal users should
not need it, disk space is a much more useful limiter).
Ah, cool! That's interesting. Thanks so much for this insight.
Thank you!
---
Regards
-Prasad
http://feedmug.com