Re: pg_ctl behavior on Windows

From: Andrew Dunstan <andrew(dot)dunstan(at)2ndquadrant(dot)com>
To: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Chapman Flack <chap(at)anastigmatix(dot)net>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_ctl behavior on Windows
Date: 2020-07-18 13:18:11
Message-ID: 05288748-cfdc-8024-73f5-7ef7f9270f83@2ndQuadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


On 7/18/20 5:46 AM, Amit Kapila wrote:
>
>> I don't have an especially easy way to experiment on Windows; I can push
>> experiments to the CI service and wait a bit to see what they do, but
>> I figured I'd ask here first.
>>
> I have tried and 'pg_ctl stuff seems to be working for a privileged
> account. See below:
> postgres.exe -D ..\..\Data
> Execution of PostgreSQL by a user with administrative permissions is
> not permitted.
> The server must be started under an unprivileged user ID to prevent
> possible system security compromises. See the documentation for
> more information on how to properly start the server.
>
> pg_ctl.exe start -D ..\..\Data
> waiting for server to start....2020-07-18 14:53:46.120 IST [8468] LOG:
> starting PostgreSQL 14devel, compiled by Visual C++ build 1915,
> 64-bit
> 2020-07-18 14:53:46.136 IST [8468] LOG: listening on IPv6 address
> "::1", port 5432
> 2020-07-18 14:53:46.136 IST [8468] LOG: listening on IPv4 address
> "127.0.0.1", port 5432
> 2020-07-18 14:53:46.214 IST [7512] LOG: database system was shut down
> at 2020-07-18 14:53:22 IST
> 2020-07-18 14:53:46.245 IST [8468] LOG: database system is ready to
> accept connections
> done
> server started
>
> I have run above two commands from an account with administrative
> privilege and 'pg_ctl start' is working. I have further tried a few
> operations after connecting with the client and everything is working
> fine.
>

This has been true for a long time, and since commit ce5d3424d6 we've
been able to run all the regression and TAP tests safely under an
administrative account.

cheers

andrew

--
Andrew Dunstan https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2020-07-18 13:24:11 Re: SQL/JSON: functions
Previous Message Chapman Flack 2020-07-18 13:00:57 Re: pg_ctl behavior on Windows