* [gentoo-user] syslog-ng + automatic respawn of target programs
@ 2006-07-04 17:28 Enrico Weigelt
2006-07-04 22:21 ` Richard Fish
0 siblings, 1 reply; 4+ messages in thread
From: Enrico Weigelt @ 2006-07-04 17:28 UTC (permalink / raw
To: gentoo-user
Hi folks,
could anyone give me a quick hint how to tell syslog-ng to
automatically respawn target programs if they die ?
I've read it quite a while ago, but I can't find it now.
thx
--
---------------------------------------------------------------------
Enrico Weigelt == metux IT service
phone: +49 36207 519931 www: http://www.metux.de/
fax: +49 36207 519932 email: contact@metux.de
cellphone: +49 174 7066481
---------------------------------------------------------------------
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] syslog-ng + automatic respawn of target programs
2006-07-04 17:28 [gentoo-user] syslog-ng + automatic respawn of target programs Enrico Weigelt
@ 2006-07-04 22:21 ` Richard Fish
2006-07-05 6:48 ` thomas blomme
0 siblings, 1 reply; 4+ messages in thread
From: Richard Fish @ 2006-07-04 22:21 UTC (permalink / raw
To: gentoo-user
On 7/4/06, Enrico Weigelt <weigelt@metux.de> wrote:
>
> Hi folks,
>
> could anyone give me a quick hint how to tell syslog-ng to
> automatically respawn target programs if they die ?
???
>From 'man syslog-ng.conf', I don't see where syslog-ng actually has
the ability to spawn "target programs" in the first place. It can log
to files, network sockets, or ttys. No mention of logging to
programs...
-Richard
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] syslog-ng + automatic respawn of target programs
2006-07-04 22:21 ` Richard Fish
@ 2006-07-05 6:48 ` thomas blomme
2006-07-05 16:03 ` Richard Fish
0 siblings, 1 reply; 4+ messages in thread
From: thomas blomme @ 2006-07-05 6:48 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 693 bytes --]
http://www.campin.net/syslog-ng/expanded-syslog-ng.conf
look at the above link, it contains all functions syslog can have
On 7/5/06, Richard Fish <bigfish@asmallpond.org> wrote:
>
> On 7/4/06, Enrico Weigelt <weigelt@metux.de> wrote:
> >
> > Hi folks,
> >
> > could anyone give me a quick hint how to tell syslog-ng to
> > automatically respawn target programs if they die ?
>
> ???
>
> From 'man syslog-ng.conf', I don't see where syslog-ng actually has
> the ability to spawn "target programs" in the first place. It can log
> to files, network sockets, or ttys. No mention of logging to
> programs...
>
> -Richard
> --
> gentoo-user@gentoo.org mailing list
>
>
--
Van
Thomas Blomme
[-- Attachment #2: Type: text/html, Size: 1467 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] syslog-ng + automatic respawn of target programs
2006-07-05 6:48 ` thomas blomme
@ 2006-07-05 16:03 ` Richard Fish
0 siblings, 0 replies; 4+ messages in thread
From: Richard Fish @ 2006-07-05 16:03 UTC (permalink / raw
To: gentoo-user
On 7/4/06, thomas blomme <blommethomas@gmail.com> wrote:
>
> http://www.campin.net/syslog-ng/expanded-syslog-ng.conf
>
> look at the above link, it contains all functions syslog can have
Ok. It is also in the documentation installed at
/usr/share/doc/syslog-ng-*/html/. So I guess it is just an omission
from the man page.
Back to the OP's question, the syslog documentation seems to make it
clear that it will not respawn the program to prevent DoS attacks. If
you want this, you can create a shell script around the program you
want to call, and handle any respawns there. A simple implementation
might be:
$program &
pid=$!
while wait $pid; do
$program &
pid=$!
done
Of course, it would be best to add in some type of abort mechanism in
case $program starts dying unexpectedly, so you don't try to exec it
1000's of times per second.
-Richard
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2006-07-05 16:13 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-04 17:28 [gentoo-user] syslog-ng + automatic respawn of target programs Enrico Weigelt
2006-07-04 22:21 ` Richard Fish
2006-07-05 6:48 ` thomas blomme
2006-07-05 16:03 ` Richard Fish
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox