GNU bug report logs -
#23064
PostgreSQL logs to stdout/stderrr, which is lost
Previous Next
Full log
View this message in rfc822 format
> Sounds like postgresql died and shepherd did not notice? Or maybe it
> keeps trying to respawn it? What did /var/log/shepherd.log say?
2016-03-19 10:34:48 Service postgres has been started.
2016-03-19 10:34:49 Respawning postgres.
2016-03-19 10:34:49 Service postgres has been started.
2016-03-19 10:34:50 Respawning postgres.
2016-03-19 10:34:50 Service postgres has been started.
2016-03-19 10:34:51 Respawning postgres.
2016-03-19 10:34:51 Service postgres has been started.
2016-03-19 10:34:52 Respawning postgres.
2016-03-19 10:34:52 Service postgres has been started.
2016-03-19 10:34:53 Respawning postgres.
2016-03-19 10:34:53 Service postgres has been started.
2016-03-19 10:34:54 Respawning postgres.
2016-03-19 10:34:54 Service postgres has been started.
> Currently the Shepherd does not do log stdout/stderr of its child
> processes, which sucks somewhat.
Yeah, that's not good.
> However, daemons can usually be told to write to syslog, which is more
> appropriate than writing things to stdout/stderr anyway.
It can always be unable to open syslog for some reason.
If shepherd can't/doesn't redirect stderr on its own, it would be nice to have init write it somewhere and everyone else inherit it as default. Just throwing it away is not nice.
But I agree, the chance of being able to write it to syslog is high. Btw: How does guixsd know to start the syslog service before the postgres service?
>What’s the right command-line/configuration option to have postgresql use syslog?
The option is
log_destination = 'syslog'
in postgresql.conf
which is generated in gnu/services/databases.scm (%default-postgres-config).
Does shepherd back off from respawing it eventually (if it respawns too fast) or will it log the same messages into syslog once every 0.1 s until my disk is full? :->
This bug report was last modified 9 years and 121 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.