Re: s6-log: Log rotation during shutdown

From: Carlos Eduardo <carana2099_at_gmail.com>
Date: Fri, 27 Feb 2026 21:50:50 -0300

Em sex., 27 de fev. de 2026, 19:17, Aleksy Grabowski <hurufu_at_gmail.com>
escreveu:

> Also, have you considered combining = action and ! processor?
> Not only to store matching log records, but also post-process them?
> For example, if you see some periodic information let's say current
> temperature, this way you can extract log line with that temperature,
> and store just the numeric value in a file.


If I understand you correctly, this could be done by inserting `/pat/ {
print | "post-process" }` awk script/`forstdin`/etc. ) in a pipeline after
`s6-log ... 1`. Either s6-rc's pipeline mechanism, or redirecting s6-log's
stdout to a plain ol' named pipe if you don't use the former.

Sometimes what I miss in s6-log is having something like `1` but for an
arbitrary preopened file descriptor, so lines can be selectively
dispatched/copied to multiple pipelines, but I haven't needed such
functionality yet.
Received on Sat Feb 28 2026 - 01:50:50 CET

This archive was generated by hypermail 2.4.0 : Sat Feb 28 2026 - 01:51:33 CET