0

I'm looking to do a tag based forwarding instead of using local1. local1 is used for other things so I don't want it to get mixed up. How can I do this? Here's my config forwarding nginx logs under /etc/rsyslog.d/nginx.conf

module(load="imfile" mode="inotify" PollingInterval="10") input(type="imfile" File="/var/log/nginx.log" Severity="info" Tag="nginx.log" Facility="local1") local1.* action(type="omfwd" target="0.0.0.0" port="2518" protocol="udp") & stop 

1 Answer 1

0

You can test for the tag with a filter such as:

if $syslogtag=="nginx.log" then action(...) & stop 

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.