To be able to keep some log history of my OpenWRT based router, I want to send it's output to a remote syslog server.
Fortunately I have another machine that is running 24/7, so I don't have to send it over the WAN link to one of my servers in the datacenter. My HTPC is running Gentoo Linux, and I configured syslog-ng as syslog daemon.
Now, by default, syslog-ng does not listen on the "Well Known" syslog port, so we have to configure it to do so. Start with adding a new source to syslog-ng.conf:
source syslog_udp {
udp(port(514));
};
We also need to configure a destination, a file in this case, where syslog-ng will write logging information received on the syslog port:
destination df_wrt0 {
file("/var/log/remote/wrt0.log");
};