Page 1 of 1

Tired of Logs flooded with systemd messages:

Posted: Thu Feb 02, 2017 3:46 pm
by SteveBeauchemin
Red Hat 7 and systemd make too much noise in my messages file.

Starting Session blah blah blah
Started Session blah blah blah
Starting Session blah blah blah
Started Session blah blah blah
Starting Session blah blah blah
Started Session blah blah blah

Finally had it up to HERE... that's right... HERE

So, I made them stop with a one line file.

Code: Select all

vi /etc/rsyslog.d/ignore-systemd-session.conf

if $programname == "systemd" and ($msg contains "Starting Session" or $msg contains "Started Session") then stop
Then restart rsyslog

Code: Select all

systemctl restart rsyslog
GONE...

Steve B

Re: Tired of Logs flooded with systemd messages:

Posted: Thu Feb 02, 2017 3:57 pm
by mcapra
Simple, effective, thanks for sharing!

You can also stop Nagios from using the syslog facility completely in nagios.cfg:

Code: Select all

use_syslog=0