Re: Uninformative messages from pg_ctl - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: Uninformative messages from pg_ctl
Date
Msg-id 1191931108.4233.4.camel@ebony.site
Whole thread Raw
In response to Re: Uninformative messages from pg_ctl  (Magnus Hagander <magnus@hagander.net>)
Responses Re: Uninformative messages from pg_ctl
List pgsql-hackers
On Tue, 2007-10-09 at 13:20 +0200, Magnus Hagander wrote:
> On Tue, Oct 09, 2007 at 01:09:19PM +0200, Peter Eisentraut wrote:
> > Am Dienstag, 9. Oktober 2007 schrieb Simon Riggs:
> > > These messages from pg_ctl are not useful
> > >
> > > $ pg_ctl -D nonexistent stop
> > > pg_ctl: PID file "nonexistent/postmaster.pid" does not exist
> > > Is server running?
> > >
> > > The message should say
> > > pg_ctl: Data Directory "nonexistent" does not exist
> > 
> > Well, this objection could apply to any place where a file is being opened.  
> > I'm curious how you plan to sort out the difference, considering that open() 
> > simply returns ENOENT in both cases.
> 
> You'd do opendir() on the directory part fisrt, I assume.

Yes, so we catch the real error.

> A question I had about it is, where are we wrt translations? When do we
> plan string freeze? 

Not one day after Beta1, I presume.

We would keep the "pid does not exist" error because it still might be
true that we have a data directory, but no pid file.

--  Simon Riggs 2ndQuadrant  http://www.2ndQuadrant.com



pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: Uninformative messages from pg_ctl
Next
From: Magne Mæhre
Date:
Subject: Re: Timezone database changes