Hi,
What I want to achieve is the following:
A message comes in (to test it I use the logger command), action 1 sends it
to server1. If I want to, action2 sends it to server2.
I read in from a text file, if it contains yes, then the second action is
also executed, if it contains
I have a conf file:
set $.doit=`cat doit`;
ruleset(name="fwd"){
action(type="omfwd"
queue.filename="t1"
queue.type="LinkedList"
queue.dequeueBatchSize="1"
target="1.2.3.4"
port="514"
action.resumeRetryCount="-1"
queue.saveOnShutdown="on"
)
if ($.doit contains "yes") then {
action(type="omfwd"
queue.filename="t2"
queue.type="LinkedList"
queue.dequeueBatchSize="1"
target="5.6.7.8"
port="514"
action.resumeRetryCount="-1"
queue.saveOnShutdown="on"
)
}
}
*.info call fwd
So, this appears to work. But I have a problem: if I put a "no" into the
file, it does not execute the second action. But it is still buffering it
... And when I reset the file to "yes" and restart the rsyslog service, it
sends the messages out.
A second problem is actually, that for whatever reason, this happens
everytime I restart the service. As if the queue is not emptied...
Any ideas why that might be?
Thanks!
--
Sent from: http://rsyslog-users.1305293.n2.nabble.com/
_______________________________________________
rsyslog mailing list
https://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE THAT.
What I want to achieve is the following:
A message comes in (to test it I use the logger command), action 1 sends it
to server1. If I want to, action2 sends it to server2.
I read in from a text file, if it contains yes, then the second action is
also executed, if it contains
I have a conf file:
set $.doit=`cat doit`;
ruleset(name="fwd"){
action(type="omfwd"
queue.filename="t1"
queue.type="LinkedList"
queue.dequeueBatchSize="1"
target="1.2.3.4"
port="514"
action.resumeRetryCount="-1"
queue.saveOnShutdown="on"
)
if ($.doit contains "yes") then {
action(type="omfwd"
queue.filename="t2"
queue.type="LinkedList"
queue.dequeueBatchSize="1"
target="5.6.7.8"
port="514"
action.resumeRetryCount="-1"
queue.saveOnShutdown="on"
)
}
}
*.info call fwd
So, this appears to work. But I have a problem: if I put a "no" into the
file, it does not execute the second action. But it is still buffering it
... And when I reset the file to "yes" and restart the rsyslog service, it
sends the messages out.
A second problem is actually, that for whatever reason, this happens
everytime I restart the service. As if the queue is not emptied...
Any ideas why that might be?
Thanks!
--
Sent from: http://rsyslog-users.1305293.n2.nabble.com/
_______________________________________________
rsyslog mailing list
https://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE THAT.