supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: Alex Efros <powerman@powerman.asdfGroup.com>
Subject: Re: monitoring svlogd-produced logfiles
Date: Thu, 15 Jun 2006 02:59:09 +0300	[thread overview]
Message-ID: <20060614235909.GA20474@home.power> (raw)
In-Reply-To: <20060614233508.GP898@annvix.org>

Hi!

There a lot of ways to do what you need and I think you overcomplicate.

If you don't need svlogd writing to disc and wish to redirect it output
to some 'summarize' program, then why not use that program instead of
svlogd in ./log/run? Main svlogd task is reliable _writing_to_disc_!

But you can configure svlogd to duplicate your logs (optionally filtered)
to STDERR (in addition to writing to disc). In degenerate case you even
can configure svlogd to write nothing to disc and send all log lines to
STDERR, but I don't understand why you need svlogd in this case. :)

Then, in ./log/run you redirect svlogd's STDERR to some FIFO file:
    svlogd /var/log/something 2>/var/log/MYFIFO
(you can configure a lot of different svlogd to output into single FIFO)
and setup special service which will fetch data from /var/log/MYFIFO,
summarize it, print colored to /dev/tty12 or everything - ./run example:
    exec my_cool_summarizer <>/var/log/MYFIFO

Only one important note about FIFOs - if your 'my_cool_summarizer'
service will be down and will not read from /var/log/MYFIFO all other
svlogd which write into FIFO will also stop soon (after they fill kernel
buffers) and in turn will stop services which they logging.

-- 
			WBR, Alex.


  parent reply	other threads:[~2006-06-14 23:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-14 23:35 Vincent Danen
2006-06-14 23:40 ` Alex Efros
2006-06-16 11:03   ` George Georgalis
2006-06-16 11:08     ` Alex Efros
2006-06-16 13:18       ` George Georgalis
2006-06-16 19:08         ` Vincent Danen
2006-06-18  2:48           ` George Georgalis
2006-06-18  2:57             ` Alex Efros
2006-06-14 23:59 ` Alex Efros [this message]
2006-06-15  0:10   ` Vincent Danen
2006-06-15  0:25     ` Alex Efros
2006-06-15  3:32       ` Vincent Danen
2006-06-15 16:32         ` Vincent Danen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060614235909.GA20474@home.power \
    --to=powerman@powerman.asdfgroup.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).