BUG #15363: Logging unexpectedly goes to system event log instead ofstderr - Mailing list pgsql-bugs

From PG Bug reporting form
Subject BUG #15363: Logging unexpectedly goes to system event log instead ofstderr
Date
Msg-id 153609661847.23143.7555891587635366496@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #15363: Logging unexpectedly goes to system event log instead of stderr
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      15363
Logged by:          Mario Emmenlauer
Email address:      mario@emmenlauer.de
PostgreSQL version: 10.3
Operating system:   Windows 7 x64
Description:

Dear All,

For the past days I've been plagued by a problem where starting postgres.exe
failed. The server postgres.exe would just not start, and stdout and stderr
where completely empty. Even with debugging mode -d 5 there was absolutely
no output. Finally I found the problem (a permission issue about being a
privileged user) with the help of a message in the system event log.

My question is not about the failed startup, but about the logging. I am
confused why the permission problem was logged to Windows system log instead
to stdout/stderr? My postgresql.conf is the default from initdb.exe and
contains only the default #log_destination = 'stderr'. The documentation at
https://www.postgresql.org/docs/current/static/runtime-config-logging.html
says "The default is to log to stderr only".

I'd like to run postgres.exe in my own watchdog, and it works nicely on
Linux and MacOSX. I was relying to see all issues on stdout/stderr. Is it
possible to do the same on Windows, to see absolutely all issues on
stdout/stderr?

Thanks a lot for the very great work, and all the best,

     Mario Emmenlauer


pgsql-bugs by date:

Previous
From: Amit Kapila
Date:
Subject: Re: BUG #15324: Non-deterministic behaviour from parallelised sub-query
Next
From: Tom Lane
Date:
Subject: Re: BUG #15363: Logging unexpectedly goes to system event log instead of stderr