Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hoL0i-0001aH-7C for pgsql-hackers@arkaria.postgresql.org; Fri, 19 Jul 2019 05:00:49 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hoL0h-00065L-2G for pgsql-hackers@arkaria.postgresql.org; Fri, 19 Jul 2019 05:00:47 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hoL0g-00065E-IH for pgsql-hackers@lists.postgresql.org; Fri, 19 Jul 2019 05:00:46 +0000 Received: from cyclops.postgrespro.ru ([93.174.131.138] helo=mail.postgrespro.ru) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1hoL0d-0000JB-Mn for pgsql-hackers@lists.postgresql.org; Fri, 19 Jul 2019 05:00:45 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.postgrespro.ru (Postfix) with ESMTP id 6181E21C2881; Fri, 19 Jul 2019 08:00:41 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at postgrespro.ru X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=x tagged_above=-99 required=4 WHITELISTED tests=[] autolearn=unavailable Received: from [192.168.1.14] (unknown [5.166.71.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id 1C95C21C2879; Fri, 19 Jul 2019 08:00:41 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1563512441; bh=C8rRogRohYkIs3+OhJPvgwSOQUS0/1NJRZZQ/hwDLnc=; h=Subject:From:In-Reply-To:Date:Cc:References:To; b=dA9jha2ZOw/kyOF1/TP/WSkIAIjDqIYDaEEc8EjPXBbW6axEzXUo61NmynvSRAmbw HT3EZGgUGBSblo6FKEImtfLck6s8HQ1vKm71EQ9fvd449mgicVWgApu4JqBHCfwFjC SmDUNdV+9ueFGuF8XL7cxkLnBfaP61MZrkH7r2m8= Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (1.0) Subject: Re: Intermittent pg_ctl failures on Windows From: =?utf-8?B?0JbQsNGA0LrQvtCyINCg0L7QvNCw0L0=?= X-Mailer: iPhone Mail (16F203) In-Reply-To: <20190719030208.GG1859@paquier.xyz> Date: Fri, 19 Jul 2019 12:00:37 +0700 Cc: Tom Lane , Badrul Chowdhury , pgsql-hackers@lists.postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <16922.1520722108@sss.pgh.pa.us> <0057a0ce5a8893e4713a9a9d7e352162@postgrespro.ru> <26631.1563371508@sss.pgh.pa.us> <3b46fc8be044c79b5eff7d26c810d2fd@postgrespro.ru> <20190718085148.GI1416@paquier.xyz> <20190719030208.GG1859@paquier.xyz> To: Michael Paquier List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk First time we found pg_ctl errors while testing our fork. I reproduced them on REL_11_STABLE. I found three problems with pg_ctl do_stop/do_restart: 1 - "old" fopen() function; 2 - "delete pending" problem rarely happens with "new" fopen() function when= pg_ctl tries to open postmaster.pid file; 3 - cmd.exe shell may block the log file when the server restarts; Now i try to reproduce it on REL_12_STABLE regard, Roman > 19 =D0=B8=D1=8E=D0=BB=D1=8F 2019 =D0=B3., =D0=B2 10:02, Michael Paquier =D0=BD=D0=B0=D0=BF=D0=B8=D1=81=D0=B0=D0=BB(=D0=B0): >=20 >> On Thu, Jul 18, 2019 at 04:14:34PM +0700, =D0=96=D0=B0=D1=80=D0=BA=D0=BE=D0= =B2 =D0=A0=D0=BE=D0=BC=D0=B0=D0=BD wrote: >> I have tested clean REL_11_STABLE. >> Commit f02259fe was reverted by df8b5f3e in this branch. >> So pg_ctl uses =E2=80=9Cold=E2=80=9D open() function. >=20 > Yeah, that was a failure from me, so I tend to be rather very careful > about anything related to Windows. However, after that we have added=20 > 40cfe86 about which nobody has complained yet, and the number of > buildfarm failures about pg_ctl concurrency on HEAD has gone down to > zero since (perhaps I am missing something?). >=20 > So, instead of trying to invent a new solution only for stable > branches (which may have its own bugs we would need to deal with only > on stable branches, and only for Windows), why don't we just try to > move forward into back-patching those pieces? Or it happens that we > still have some potential failures on HEAD and REL_12_STABLE which > would justify some extra handling? In this case, I would recommend > that we focus on HEAD as a first step, and put things in order there. > -- > Michael