Transform::Alert::Input::Syslogd - Transform alerts from an internal Syslog daemon
# In your configuration <Input test> Type Syslogd Interval 5 # you should set this to be very short # See Net::Syslogd->new <ConnOpts> LocalAddr 192.168.1.1 LocalPort 514 # default # Timeout - don't bother </ConnOpts> # <Template> tags... </Input>
This input type will spawn a syslog listener and process each message through the input template engine. If it finds a match, the results of the match are sent to one or more outputs, depending on the group configuration.
See Net::Syslogd for a list of the ConnOpts section parameters. The Timeout parameter is basically ignored, since get_message calls will use a timeout of 0 (ie: instant). This is so that the main daemon doesn't bother waiting for messages during each heartbeat. As such, the Interval setting should be set very low. (But, not zero; that would be unwise...)
Timeout
get_message
Interval
$addr:$port - $datagram
{ remoteaddr => $str, remoteport => $int, priority => $int, facility => $str, # text version severity => $str, # text version time => $str, hostname => $str, message => $str, }
The project homepage is https://github.com/SineSwiper/Transform-Alert/wiki.
The latest version of this module is available from the Comprehensive Perl Archive Network (CPAN). Visit http://www.perl.com/CPAN/ to find a CPAN site near you, or see https://metacpan.org/module/Transform::Alert/.
Brendan Byrd <BBYRD@CPAN.org>
This software is Copyright (c) 2013 by Brendan Byrd.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
To install Transform::Alert, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Transform::Alert
CPAN shell
perl -MCPAN -e shell install Transform::Alert
For more information on module installation, please visit the detailed CPAN module installation guide.