supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: Henrik Heil <hhml@zweipol.net>
Subject: Re: svlogd -tt
Date: Thu, 29 Jul 2004 15:07:26 +0200	[thread overview]
Message-ID: <4108F68E.6080600@zweipol.net> (raw)
In-Reply-To: <20040729111258.GA4786@home.power>

>>I know that i can use the mtime to select the logfiles.
>>Thanks for the examples anyway. I still think that this is kind of a 
>>workaround.
>>With the mtime approach you could argue that there is no need for a 
>>timestamp in the filenames at all. Even without mtime you could do a 
>>script that looks in all the files to select ranges.
>>In my opinion a log processor program would the preferable solution and 
>>fit well in the runit-suite.
> 
> Hmm... how about this idea for log processor program:
> 1) svlogd execute processor which just fork in background and return log file
>    without changes back to svlogd
> 2) svlogd remove old TAI-logfile and create new TAI-logfile
> 3) processor (forked in background) notice log rotation is done (how?) and then:
>     1) execute 'ln newTAIlogfile newLOCALTIMElogfile' to create hard linked file
>     2) search for some oldLOCALTIMElogfile with only one hardlink to it (because
>        oldTAIlogfile which was hardlinked to it was just removed by svlogd) and
>        remove it too
>     3) exit
> 
> Maybe it's better to do this work in cron-script instead of log processor.

Sorry for my ambiguous writing -- i meant the "svlogp" program that 
Gerrit mentioned and described like this:

> I've been thinking about a "svlogp" program (svlog processor, or pager)
> for some time, which should be able to select log message by pattern or
> time, to merge logs from multiple log directories, and maybe to
> transform timestamps and more.

With svlogp the format of filenames and timestamps wouldn't matter 
anymore. You could for example [my interpretation] specify one or more 
logdir(s), your favorite timeformat, from-date and to-date (in that 
timeformat) on the command line and get the merged logmessages for that 
range on stdout, lines prefixed with a timestamp in the given format.

Best regards,
Henrik

-- 
Henrik Heil, zweipol Coy & Heil GbR
http://www.zweipol.net/


      reply	other threads:[~2004-07-29 13:07 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-20 19:00 Henrik Heil
2004-07-23 10:20 ` Gerrit Pape
2004-07-23 10:30   ` Ian Stokes-Rees
2004-07-26 18:39   ` Henrik Heil
2004-07-27 11:28     ` Gerrit Pape
2004-07-27 12:31       ` Henrik Heil
2004-07-28 23:02 ` Alex Efros
2004-07-29 10:12   ` Henrik Heil
2004-07-29 11:12     ` Alex Efros
2004-07-29 13:07       ` Henrik Heil [this message]

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=4108F68E.6080600@zweipol.net \
    --to=hhml@zweipol.net \
    /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).