Skip site navigation (1) Skip section navigation (2)

Re: win32 service code

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: pgsql-hackers-win32 <pgsql-hackers-win32(at)postgresql(dot)org>
Subject: Re: win32 service code
Date: 2004-05-27 21:14:47
Message-ID: 40B65A47.1000706@dunslane.net (view raw or flat)
Thread:
Lists: pgsql-hackers-win32
Merlin Moncure wrote:

>Andrew wrote:
>  
>
>>>I had a thought that on win32 pg_ctl start/stop would mean start/stop
>>>the service (always) on win32, and for this to be the only way to
>>>      
>>>
>start
>
>  
>
>>No, we need to be able to run *not* under the service manager, and
>>pg_ctl needs to be able to control that, IMNSHO.
>>
>>Users might not have admin privs (e.g. in a classroom setting).
>>    
>>
>
>Ok, fair enough.  Do you think start/stop service should still be done
>through pg_ctl?
>
>
>  
>

I think if we are running as a service that the SCM code should create 
$PGDATA/pgservice.servicename so we can at least detect it.

Then if that file is present, we have a range of options, including:
. don't allow pg_ctl to do stop/start/restart
. have pg_ctl issue "net {stop,start} servicename" to give effect to the 
commands

cheers

andrew



In response to

pgsql-hackers-win32 by date

Next:From: Andrew DunstanDate: 2004-05-27 21:19:21
Subject: Re: win32 service code
Previous:From: Magnus HaganderDate: 2004-05-27 21:12:15
Subject: Re: win32 service code

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group