rsyslog exclude
Helmut Schneider
jumper99 at gmx.de
Mo Sep 5 16:26:28 UTC 2011
Helmut Schneider wrote:
> ich habe leider nur Ahnung mit BSD syslogd und da rsyslog sagt:
>
> "Please note that the "#!prog", "#+hostname" and "#-hostname" syntax
> available in BSD syslogd is not supported by rsyslogd"
>
> frag ich mal hier.
>
> Ich hab einen Loghost, der u.a. Meldungen von Apache logged. Dafür
> habe ich konfiguriert:
>
> $ cat /etc/rsyslog.d/apache.conf
> local7.* /var/www/logs/error_log
> local6.* /var/www/logs/access_log
>
> Nun landet leider alles zusätzlich in /var/log/syslog.
>
> Wie verhindere ich das sauber? Sauber soll heissen, es soll wirklich
> nur local6.* und local7.* nicht in /var/log/syslog landen.
Wenn man weiss, wonach man suchen muss...
if $syslogfacility-text == 'local7' and $programname == 'httpd' then
/var/www/logs/error_log
if $syslogfacility-text == 'local7' and $programname == 'httpd' then ~
if $syslogfacility-text == 'local6' and $programname == 'httpd' then
/var/www/logs/access_log
if $syslogfacility-text == 'local6' and $programname == 'httpd' then ~
Mehr Informationen über die Mailingliste ubuntu-de