Hi,
On my logging server named rack1a I have at the top of my rsyslog.conf
these lines
$template DynaFile,"/var/log/%HOSTNAME%/%PROGRAMNAME%.log"
if $hostname <> 'rack1a' then -?DynaFile
& ~
the intent being that I'd like to collect messages from some services
(%PROGRAMNAME%) from other machines
and store them in their own files. I'd like the conf files to not have a
dependency on their name. However,
when I write lines like
if $hostname <> $myhostname then -?DynaFile
or
if $hostname <> $fromhostname then -?DynaFile
or even
if $hostname <> getenv('HOSTNAME') then -?DynaFile
rsyslogd creates /var/log/rack1a/%PROGRAMNAME%.log files in addition to the
logs for the external programs.
What am I doing wrong here? I'm using rsyslog 5.6.0v5(stable).
-- Brian
<<winmail.dat>>
_______________________________________________ rsyslog mailing list http://lists.adiscon.net/mailman/listinfo/rsyslog http://www.rsyslog.com

