On Thu, 25 Apr 2013, Aleksandr wrote:
Hi all,could someone help with creating rsyslog configuration for rewriting/deleting part of message. Position of this part is dynamic (it can be on different position in syslog message). I have looked The Property Replacer documentation, but looks like it can't be achieved with it. OS: Debian Stable (Squeeze) Rsyslog version: 5.8.11-1~bpo60+2 PS. In syslog-ng it is possible with creating rewrite rule. rewrite test_rule { subst("SOME_TEXT_FOR_REPLACE", "NEW_TEXT", value("MSG")); };
rsyslog does not have rewrite rules. I believe that it would be possible to write a mm module to do this.
Am I understanding that this would be the equivalent of echo "MSG" |sed s/SOME_TEXT_FOR_REPLACE/NEW_TEXT/g ? David Lang _______________________________________________ rsyslog mailing list http://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.

