[rsyslog] log *.*, except logs by "postgres"

Tomasz Chmielewski mangoo at wpkg.org
Thu Mar 18 21:21:06 CET 2010


I have postgres logging to a separate file through rsyslog with this line:

local0.*                -/var/log/postgresql/postgresql_log


It gets to /var/log/syslog as well, thanks to this line:

*.*;auth,authpriv.none	-/var/log/syslog


As postgres is set to log quite heavily, I would rather not log postgres into /var/log/syslog.

I've read some filtering examples, but I couldn't find one on excluding a given program from a file which is logging everything.

Could anyone point me to a proper example?


Postgres adds such entries through syslog:

Mar 19 04:14:16 sun postgres[388]: [261-1] 2010-03-19 04:14:16 SGT LOG:  duration: 0.037 ms  statement: ROLLBACK


-- 
Tomasz Chmielewski
http://wpkg.org



More information about the rsyslog mailing list