Often, there are some messages that you know you will never store in any log
file. Even worse, these messages are sometimes very frequently emitted. There
are various ways to get rid of those unwanted messages.
First of all, you need to identify them. Then look carfully and see what is
special with these messages. A common case may be that they contain a specific
text inside the message itself. If so, you can filter on that text and discard
anything that matches. You need to be careful, though: if there are other
messages matching this text, these other messages will also be discarded. So it
is vital to make sure the text you use is actually unique.
In the sample below, let's assume that you want to discard messages that
contain either the text ``user nagios'' or ``module-alsa-sink.c: ALSA woke us
up to write new data to the device, but there was actually nothing to
write''. The later is an actual sample from pulseaudio, which is known to spam
syslog with an enourmous volume of these messages.