Customize rsyslogd messages to show the sender of the message; not the receiver

Posted by Nimmy Lebby on Server Fault See other posts from Server Fault or by Nimmy Lebby
Published on 2010-12-25T01:23:01Z Indexed on 2010/12/25 1:55 UTC
Read the original article Hit count: 571

Filed under:
|
|
|

I'm forwarding the WiFi router's log messages to our sysadmin box (sb3). This is the stanza in /etc/rsyslog.conf:

# WiFi router log
:fromhost-ip, isequal,'10.3.291.2'           /var/log/wifi-router.log
& ~

However, the log looks like this:

Dec 23 10:41:58 sb3 dnsmasq-dhcp[253]: DHCPACK(br0) 10.3.292.133 xx:xx:xx:xx:xx:xx dg-ipad

I want to customize so that anything logged to wifi-router.log does not mention sb3 but indicates the sender of the log message. How would I do this?

© Server Fault or respective owner

Related posts about linux

Related posts about configuration