I need to dump the data out of a TP-Link router / modem (192.168.1.1) to a PI running a Feb version of Lite (that's the only computer on 24*7) and was thinking about using rsyslog to help me filter out the 'noise' with a selection file in /etc/rsyslog.d/ like this:
# Provide TCP syslog reception
module(load="imtcp")
input(type="imtcp" port="514")
if $fromhost-ip == '192.168.1.1' then {
if $msg contains 'VoIP' then {
stop
}
if $msg contains 'System: LAN' then {
action(type="omfile" File="/var/log/rtr-lan.log")
stop
}
# Everything else defalts
action(type="omfile" File="/var/log/rtr-wan.log")
}
This will then ignore the VOIP data (currently 90%+ of the router log is this) and split LAN noticed from WAN notices.
The first concern I have is, would this clash with the normal journald logging on the PI?
The second is, should I configure the facility on the router to User (its default) or Localx where x is 0 to 7 inclusive to keep the normal log running?