Lists: | pgsql-hackers |
---|
From: | Dave Cramer <pg(at)fastcrypt(dot)com> |
---|---|
To: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | pg_ctl less than useful error message on windows when privileges wrong for postgres |
Date: | 2008-10-21 19:45:24 |
Message-ID: | D55CB95B-C4A9-48C6-8F38-78EAC86F2632@fastcrypt.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers |
I have a client who mistakenly gave the postgres user on a windows
machine admin privileges.
This mistake results in the service being unable to start up due to
postgres refusing to start with admin privileges.
The error message from pg_ctl start -D bindir is PG_CTL.."could not
locate matching postgres executable"
Is it not possible to provide a more useful error message ?
Dave
From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Dave Cramer <pg(at)fastcrypt(dot)com> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_ctl less than useful error message on windows when privileges wrong for postgres |
Date: | 2008-10-21 21:24:03 |
Message-ID: | 10096.1224624243@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers |
Dave Cramer <pg(at)fastcrypt(dot)com> writes:
> I have a client who mistakenly gave the postgres user on a windows
> machine admin privileges.
> This mistake results in the service being unable to start up due to
> postgres refusing to start with admin privileges.
> The error message from pg_ctl start -D bindir is PG_CTL.."could not
> locate matching postgres executable"
It's fairly hard to see how that mistake leads to that symptom.
Can you poke a bit more into exactly what is happening?
regards, tom lane
From: | Dave Cramer <pg(at)fastcrypt(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_ctl less than useful error message on windows when privileges wrong for postgres |
Date: | 2008-10-21 21:57:28 |
Message-ID: | 2C9A234A-9388-415C-9F46-49962D337D98@fastcrypt.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers |
On 21-Oct-08, at 5:24 PM, Tom Lane wrote:
> Dave Cramer <pg(at)fastcrypt(dot)com> writes:
>> I have a client who mistakenly gave the postgres user on a windows
>> machine admin privileges.
>
>> This mistake results in the service being unable to start up due to
>> postgres refusing to start with admin privileges.
>
>> The error message from pg_ctl start -D bindir is PG_CTL.."could not
>> locate matching postgres executable"
>
> It's fairly hard to see how that mistake leads to that symptom.
> Can you poke a bit more into exactly what is happening?
>
find_my_exec returns -1 for a number of errors resulting in an error
message much like above (wording is slightly different).
when I executed postgres.exe directly it complained of the user having
admin privs
I removed admin privs from the pg user and pg_ctl worked fine.
I know it's not very specific, but fairly damning.
Dave
From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Dave Cramer <pg(at)fastcrypt(dot)com> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_ctl less than useful error message on windows when privileges wrong for postgres |
Date: | 2008-10-22 02:45:57 |
Message-ID: | 15265.1224643557@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers |
Dave Cramer <pg(at)fastcrypt(dot)com> writes:
> On 21-Oct-08, at 5:24 PM, Tom Lane wrote:
>> It's fairly hard to see how that mistake leads to that symptom.
>> Can you poke a bit more into exactly what is happening?
> when I executed postgres.exe directly it complained of the user having
> admin privs
With no arguments, that's not surprising; but pg_ctl invokes it with the
-V option, which should result in a version response occurring before
the root-privileges check (look at main/main.c). So I think there's
something going on here that you've not identified.
regards, tom lane