I`m logging my network equipment with rsyslog on a Ubuntu 10.04 server.
This works quite well, except a strange problem with my Mikrotik equipment.
On the Mikrotik boxes I run ROS 3.30
When syslog eneries appear from these, host name is very strange.
It can be:
wireless,debug
wireless,info
How can I correct this, and just get a host name here?
Its hostname from the mikrotik units that seems to be different from other devices.
In hostname field I get “wireless,debug” “wireless,info” and so on.
The %hostname% from a MT is messed up and gives you <facility,severity> instead. Replace %HOSTNAME% with %fromhost% as a work around, it wont give you the DNS hostname but it will at least give you an IP address.
if ($fromhost-ip == ‘’) then mmysql:127.0.0.1,,,;TikRouters
I know this caused me some frustration for quite some time, and I hope that my solution helps someone else. If anyone finds a better solution I would be more than happy to hear it/use it.