Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Here is 9 year old bug that is still not fixed:

https://github.com/systemd/systemd/issues/2460

Long story short: there is no useful indexing in journald DB format which means looking for say "last message app emitted" means looking thru every file.

As long as it is mmaped in or on tmpfs it is reasonably fast, but if you say have last 1GB of logs stored on spinning rust on NAS.... you either have 3-4 second wait till it finds those few log lines, or buffer cache littered with that GB of logs, pushing out actually useful stuff.

It literally have worse performance than grepping entire /var/log last time I checked.

And it seems in its entirety it was "Lennart wanted to make a binary log format" vs something actually useful... just having SQLite DB instead would on top of being faster far more useful (ability to SQL query logs on local node with no extra fuss would be awesome)



Thanks, interesting. (This is something I had actually observed, too, but never had the patience to figure out what was happening.)

I like the SQLite idea.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: