Re: Idea: closing the loop for "pg_ctl reload"

From: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
To: Jan de Visser <jan(at)de-visser(dot)net>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Idea: closing the loop for "pg_ctl reload"
Date: 2015-03-03 17:23:31
Message-ID: 54F5EE13.9060208@BlueTreble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 3/3/15 11:15 AM, Jan de Visser wrote:
> On March 3, 2015 11:09:29 AM 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)?
>
> Not impossible. I can play around with that and see if it's as straightforward
> as I think it is.

I'm sure the code side of this is trivial; it's a question of why Tom
was objecting. It would probably be better for us to come to a
conclusion before working on this.

On a related note... something else we could do here would be to keep a
last-known-good copy of the config files around. That way if you flubbed
something at least the server would still start. I do think that any
admin worth anything would notice an error from pg_ctl, but maybe others
have a different opinion.
--
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim Nasby 2015-03-03 17:24:38 Re: logical column ordering
Previous Message Bruce Momjian 2015-03-03 17:23:04 Re: logical column ordering