From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/1570 Path: news.gmane.org!not-for-mail From: Larry Doolittle Newsgroups: gmane.comp.sysutils.supervision.general Subject: svlogd research Date: Fri, 16 Nov 2007 11:57:17 -0800 Message-ID: <20071116195717.GA10933@recycle.lbl.gov> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1195243049 24445 80.91.229.12 (16 Nov 2007 19:57:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 16 Nov 2007 19:57:29 +0000 (UTC) To: supervision@list.skarnet.org Original-X-From: supervision-return-1805-gcsg-supervision=m.gmane.org@list.skarnet.org Fri Nov 16 20:57:35 2007 Return-path: Envelope-to: gcsg-supervision@gmane.org Original-Received: from antah.skarnet.org ([212.85.147.14]) by lo.gmane.org with smtp (Exim 4.50) id 1It7Jl-0007fU-TE for gcsg-supervision@gmane.org; Fri, 16 Nov 2007 20:57:33 +0100 Original-Received: (qmail 32341 invoked by uid 76); 16 Nov 2007 19:57:36 -0000 Mailing-List: contact supervision-help@list.skarnet.org; run by ezmlm List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Archive: Original-Received: (qmail 32336 invoked from network); 16 Nov 2007 19:57:36 -0000 Content-Disposition: inline User-Agent: Mutt/1.5.17 (2007-11-01) Xref: news.gmane.org gmane.comp.sysutils.supervision.general:1570 Archived-At: Gerrit and friends - I'm trying to create a tricky (for me) setup for svlogd, and have some questions. I want both a reliable local log, and an encrypted (via stunnel) remote log, where I can't control the reliability of the remote logging machine (or the network path to it). My environment is Debian sid amd64, currently runit 1.8.0-1. So my /etc/runit/proggie/log/run file must look something like #!/bin/sh exec svlogd -t /var/log/proggie_local /var/log/proggie_remote where /var/log/proggie_local is familiar territory. /var/log/proggie_remote doesn't look too bad. Every couple of minutes I want to dump the accumulated logs (if any) to the remote server, so I have lines in that directory's config file like t120 ! /usr/sbin/stunnel blah blah blah -r syslog.example.org:5140 My core question is what happens when stunnel fails or stalls. The svlogd man page says A processor is run in the background. If svlogd sees a previously started processor still running when trying to start a new one for the same log, it blocks until the currently running processor has finished successfully. Only the HUP signal works in that situation. Note that this may block any program feeding its log data to svlogd. That would be bad, since the same svlogd process is also responsible for the local log. Network stalls shouldn't affect proggie or its local logging. When I look in the code for how this is supposed to work, I see the check for a still-running processor for the previous data set if (ld->ppid) { warnx("processor already running", ld->name); return(0); } but no caller to this routine checks for an exit code, and nothing retries the call to processorstart(). So it looks like if one processor run stalls indefinitely, no additional data will ever get sent to the processor, and the svlogd process never stalls. This doesn't sound like what the documentation says. Is my analysis correct? Am I on the right track in general? - Larry