Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] [OT] attach a perl script to daemon services
Date: Fri, 26 Feb 2010 20:25:55
Message-Id: 201002262222.08735.alan.mckinnon@gmail.com
In Reply to: [gentoo-user] [OT] attach a perl script to daemon services by Harry Putnam
1 On Friday 26 February 2010 20:40:40 Harry Putnam wrote:
2 > ALERT [ This is a slightly rewritten repost from
3 > `gmane.[...].perl.beginners', where it got no responses]
4 > ------- --------- ---=--- --------- --------
5 >
6 > My subject line is probably not really that
7 > good at describing what I want advice on but here it is:
8 >
9 > I've setup one linux (gentoo) box as a logserver running rsyslog and
10 > several other linux boxes sending syslog info to it.
11 >
12 > I want to set the server rsyslog.conf so that in addition to normal
13 > logging to /var/log/whateverlogs it also writes everything to a named
14 > pipe (fifo).
15 >
16 > Then tap into the fifo with a perl script that is written to be able
17 > to sort and write the syslog output according to various regex that
18 > may be part of startup cmd or fed in later during the running script.
19
20 I don't know rsyslog at all (I use syslog-ng), but certain concepts are stable
21 and universal.
22
23 Any log daemon must receive logs from somewhere and send them somewhere, and
24 almost all support the notion of sending logs to a process instead of a file-
25 like destination.
26
27 Does rsyslog not support something like this:
28
29 destination "| /path/to/script.pl"
30
31
32 --
33 alan dot mckinnon at gmail dot com

Replies

Subject Author
[gentoo-user] Re: [OT] attach a perl script to daemon services Harry Putnam <reader@×××××××.com>