Re: Logging (was Re: PostgreSQL 7.0-2 RPMset released.)
От | Giles Lean |
---|---|
Тема | Re: Logging (was Re: PostgreSQL 7.0-2 RPMset released.) |
Дата | |
Msg-id | 3981.958977780@nemeton.com.au обсуждение исходный текст |
Ответ на | Logging (was Re: PostgreSQL 7.0-2 RPMset released.) (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-general |
On Mon, 22 May 2000 00:19:45 -0400 Tom Lane wrote: > There needn't be a lot of code involved, we just need a > well-thought-out spec for how it should work. Comments anyone? I run postmaster under Dan Bernstein's "daemontools", which include logging facilities: http://cr.yp.to/daemontools.html The summary of this setup is that postmaster runs in the forground writing error messages to standard error, and standard error is a pipe to another process. The second process is responsible for selecting messages to write, writing them, and rotating the log file. More traditional Unix solutions would involve teaching postmaster what the name of its log file is, and to reopen it on receipt of some signal. Usually SIGHUP is used since SIGHUP is unlikely to be useful to a daemon running in the background. There are issues for logging errors that many applications handle badly. What happens when: o there is an I/O error writing to a log file? o the log file is at maximum size? o the filesystem the log file is in is full? o a write to a log file blocks? To take a not random example, syslogd is OK for log file rotation but makes a mess and a muddle of things otherwise including the points I list. Regards, Giles
В списке pgsql-general по дате отправления: