4

Using Archlinux aarch64, I have an error message that keeps happening, which apparently cannot be solved, at least not simply (see this question). Since it occurs very frequently I am concerned about log size, and the storage being a micro-sd card, about its premature wear.

Is there a way to not logs these messages? I see in journald doc it's possible to limit by rate or max size, but I don't see anything for what I want. Ideally it would not filter out the unit completely, since the message is from the kernel.

The error message is always the same, so maybe there's another trick?

5

From reading man systemd-journald and man journald.conf, I don't see an option for discarding incoming logics, which is possible with or logging daemons like rsyslog.

The workarounds I'm aware of are:

  1. Logging into memory instead of the filesystem-- Set Storage=volatile in journald.conf. The volatility is an obvious tradeoff.
  2. The ability to limit the maximum space consumed by the logs with SystemMaxUse= and RunTimeMaxUse=.

A more extreme workaround is to use the options above to limit the resource consumption by the systemd journal, while also forwarding the logs on to another logging daemon which has a filtering feature.

See man journald.conf for ForwardToSyslog= and other options.

  • 1
    Memory storage + small max size + forwarding & filtering in syslog means I keep all important logs without the hassle and wear of these flooding messages. Neat idea, thx. – Antoine Jan 9 '17 at 21:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.