Re:Running systemd without systemd-journald
by quotemstr on Sunday June 19, 2022 @03:35PM
(#31802596)
It's not quite that simple: while clean file-backed pages are cheaper than, say, private dirty pages (which the kernel must preserve as long as anyone references them), they're not free: you're still paying an opportunity cost. That is, the kernel is, at least for a time, keeping each clean file-backed page resident when it could be keeping some other page, perhaps a more useful one, in RAM instead. If systemd-journald is append-mostly, it'd be useful to MADV_FREE (after msync) any pages behind the current write pointer so as to give the kernel a hint that it can get rid of those clean file-backed pages early. I'd actually suggest getting rid of the use of memory mapping entirely, but doing so would likely be a bigger ask.
[ Parent
| on HN ]
Re:Running systemd without systemd-journald
by viraptor on Sunday June 19, 2022 @04:28PM
(#31803153)
> the kernel is, at least for a time, keeping each clean file-backed page resident when it could be keeping some other page
It's almost the same result for the standard page cache when you're reading a file, isn't it?