Hey! Has somebody using rsyslog to forward result ...
# fleet
r
Hey! Has somebody using rsyslog to forward result logs to remote logging server? I’m using the following configuration in /etc/rsyslog.d/osquery.conf: module(load=“imfile” mode=“inotify”) input(type=“imfile”  File=“/var/log/osquery/result.log”  Tag=“fleet:”  PersistStateInterval=“300"  Severity=“info”  Facility=“local6" ) if $programname == ‘fleet’ then @@ip_adress:518 The problem is that following configuration doesn’t work, however when I change protocol to udp (delete one @ symbol) everything works fine. Any ideas?
z
Sorry for the kinda basic response, but are you sure the syslog reciever is listening on TCP? Considering that it works over UDP, this might be worth checking out.
Its quite common for syslog servers to listen on UDP instead of TCP.
r
@Zachary Winnerman The rsyslog reciever is listening on TCP, and the port is open, i checked.
z
so curiously, is it listening on both TCP and UDP on the same port?
r
@Zachary Winnerman no, I just checked that udp is working with tcpdump
z
Ah, ok, so you will always see UDP packets transmitting regardless of if the other side is setup to receive them. Did you peek inside them to make sure that its sending the correct data curiously or just look at the headers?
Considering that rsyslog is sending messages in UDP mode. It seems that rsyslog is configured correctly. I would look into the networking side next. Maybe a firewall is blocking traffic? This could be on either host with iptables or an appliance inbetween. I have no idea what your network looks like so sorry if this comes across as strange.
You can get some additional information about whats going on by starting rsyslogd in your terminal with the
-d -n
flags