Received: from makus.postgresql.org ([98.129.198.125]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TF4oX-0005Qf-0f for pgsql-general@postgresql.org; Fri, 21 Sep 2012 15:06:45 +0000 Received: from mail-gh0-f174.google.com ([209.85.160.174]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TF4oV-0002mC-N3 for pgsql-general@postgresql.org; Fri, 21 Sep 2012 15:06:44 +0000 Received: by ghbg15 with SMTP id g15so1034238ghb.19 for ; Fri, 21 Sep 2012 08:06:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:references:in-reply-to:subject:date:message-id :mime-version:content-type:content-transfer-encoding:x-mailer :thread-index:content-language:x-gm-message-state; bh=xawpj4QhWfofhmJkgYWJxRi36Ux3bWsG7M8hQXgjVR4=; b=myRx7yL/9eW8QSI3Ra9Zx9eLgkBFsDKKCxRzpfV/QzdvQs37+oSIvrfbPHEYN48kxs tTd13lSyA/ewx/rKuVoiqPbcbfGZvs9SXpjpUezQfKT4gQR/P8ZJ2da8DQcG7oKwcoVu hJEauZS24Oz9GNamtnW3oKAHzIbpYWupKY5vRIKGRtriCIT+DZQ976NUNlH+cb1I13J9 dKNgIupJO4B/tHHy22Jd5ZiSCtztkKsI64dWEQz6aEHtoM3y2bh+n5X+ug4/36MA1HOA pObdfdFgXP2PkDjxJr51buVvUu5rSAw63WB59cWgSIfRz8ss+pDF8mQmDwg41JlkVA60 Bw6Q== Received: by 10.236.153.9 with SMTP id e9mr5551325yhk.32.1348240002647; Fri, 21 Sep 2012 08:06:42 -0700 (PDT) Received: from AnibalVAIO (host-1-86.b20.cvc.com.py. [186.2.211.86]) by mx.google.com with ESMTPS id l25sm13298888yhk.8.2012.09.21.08.06.40 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 21 Sep 2012 08:06:41 -0700 (PDT) From: "Anibal David Acosta" To: "'Craig Ringer'" , "'Vincent Dautremont'" Cc: References: <5056AA3F.7020407@ringerc.id.au> In-Reply-To: Subject: Re: [ADMIN] Windows Services and Postgresql 9.1.3 Date: Fri, 21 Sep 2012 11:06:44 -0400 Message-ID: <007c01cd980a$b8c2c700$2a485500$@devshock.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQJq8rvavygXY/ZAeCUAlEuYNxpZmwHJwSgflkZBDGCABaBN4A== Content-Language: es-py X-Gm-Message-State: ALoCoQk/L6Wtv3TlwnP7lwmnu61IbvmSDaB3dbnILgBTkaqwLB9DexQjMpou+2CM5RXmUe4Nu/ot X-Pg-Spam-Score: -2.6 (--) X-Archive-Number: 201209/692 X-Sequence-Number: 190708 Yes, (I think) is a Bug, sometimes in some circumstances pg_ctl go down but postgres server still running. You can easily reproduce. Go to "task manager", kill the process "pg_ctl" (simulate some kind of crash or something else). Now go to services management and try to start again. Start command will through an error because pg_ctl can't start database because is already started. Due to this bug I always use the pg_ctl command directly and not the windows service. Running pg_ctl command from command prompt show that postgres server is running, but windows service show stopped and is not possible to start again from windows service UI The windows service also can remain in an inconsistent state when the pg_ctl can't stop the postgres server. I think that pg_ctl uses stop "fast" so, if for some reason postgres don't response to stop fast, the service in windows service UI appear as stopping for long time and finally after some kind of timeout it show as not started. Obviously, if it appear as not started you want to start, but you can't. And maybe some inexperienced user get crazy, "database is stopped and can't start" but really DB is started. What the inexperienced do is the only thing he can do... Restart the server, when he restart the postgres server receive a KILL message and then everything get worse I live this situation time ago and obviously learn :) Regards -----Mensaje original----- De: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] En nombre de Craig Ringer Enviado el: lunes, 17 de septiembre de 2012 12:43 a.m. Para: Vincent Dautremont CC: pgsql-admin@postgresql.org Asunto: Re: [ADMIN] Windows Services and Postgresql 9.1.3 On 09/12/2012 04:48 AM, Vincent Dautremont wrote: > For example, after the server had rebooted, I would stop the service > from services.msc Windows then reports it as stopped but I can still > see that the database is running, and can use it. Check in the process monitor (or, better, with Process Explorer from Sysinternals) to see what user the `postgres.exe` processes are running as. > When I would start the service again, I would end up with a timeout > waiting for the service to be started. When in fact the database was > always running. > > Anyone had that bug/problem before ? Nope. Sounds completely crazy. More info needed, though. -- Craig Ringer -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin