On 3/3/15 11:33 AM, Andres Freund wrote:
> On 2015-03-03 11:09:29 -0600, Jim Nasby wrote:
>> On 3/3/15 9:26 AM, Andres Freund wrote:
>>> On 2015-03-03 15:21:24 +0000, Greg Stark wrote:
>>>> Fwiw this concerns me slightly. I'm sure a lot of people are doing
>>>> things like "kill -HUP `cat .../postmaster.pid`" or the equivalent.
>>>
>>> postmaster.pid already contains considerably more than just the pid. e.g.
>>> 4071
>>> /srv/dev/pgdev-master
>>> 1425396089
>>> 5440
>>> /tmp
>>> localhost
>>> 5440001 82345992
>>
>> If we already have all this extra stuff, why not include an actual error
>> message then, or at least the first line of an error (or maybe just swap any
>> newlines with spaces)?
>
> It's often several errors and such. I think knowing that it failed and
> that you should look into the error log is already quite helpful
> already.
It's certainly better than now, but why put DBAs through an extra step
for no reason? Though, in the case of multiple errors perhaps it would
be best to just report a count and point them at the log.
> Generally we obviously need some status to indicate that the config file
> has been reloaded, but that could be easily combined with storing the
> error message.
Not sure I'm following... are you saying we should include the error
message in postmaster.pid?
--
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com