Re: [PATCH] better systemd integration - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCH] better systemd integration
Date
Msg-id 324.1447777986@sss.pgh.pa.us
Whole thread Raw
In response to [PATCH] better systemd integration  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> I have written a couple of patches to improve the integration of the
> postgres daemon with systemd.

Seems like a generally reasonable thing to do.  systemd is probably
not going away (unfortunately IMO, but there it is).

> The second patch improves integration with the system journal managed by
> systemd.  This is a facility that captures a daemon's standard output
> and error and records it in configurable places, including syslog.  The
> patch adds a new log_destination that is like stderr but marks up the
> output so that systemd knows the severity.  With that in place, users
> can choose to do away with the postgres log file management and let
> systemd do it.

One of the benefits of the log collector is that it's able to do something
reasonably sane with random stderr output that might be generated by
libraries linked into PG (starting with glibc...).  If someone sets things
up as you're suggesting, what will systemd do with unlabeled output lines?
Or in other words, how much value-add is there really from this markup?

Also, it looks like the markup is intended to be per-line, but as you've
coded this a possibly-multi-line error report will only have a prefix
on the first line.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Oleg Bartunov
Date:
Subject: new full text search configurations
Next
From: Pavel Stehule
Date:
Subject: Re: new full text search configurations