Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p2cTk-0002so-4Y for pgsql-hackers@arkaria.postgresql.org; Tue, 06 Dec 2022 18:15:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1p2cTj-0002Qs-1K for pgsql-hackers@arkaria.postgresql.org; Tue, 06 Dec 2022 18:15:39 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p2cTi-0002Qi-Nm for pgsql-hackers@lists.postgresql.org; Tue, 06 Dec 2022 18:15:38 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p2cTg-0002wX-7j for pgsql-hackers@lists.postgresql.org; Tue, 06 Dec 2022 18:15:38 +0000 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 3DF255C0088; Tue, 6 Dec 2022 13:15:35 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 06 Dec 2022 13:15:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=anarazel.de; h= cc:cc:content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to; s=fm1; t=1670350535; x=1670436935; bh=YxOc+fQckF ki78WcCm77tq5zHWCFur5uD9eIzM2tcsU=; b=k1ziliZ3PRwt382xUVLgdJr0au ePV7KWdVbK56cCbGYDDccETLVRISaXxYmxL30jO9FXd8yKwSp2zFtYX9hvggWOXP uQjijN45NXASlGSQJ/nFs2FamkIECpxfVaVuY5vU7CjbNbRdAQn8IV2VvolPuarG Wi2oYmQVdM/hjYNFjzN4eSQcVA5FPmx2p+mLrOYbbo2xVThnjAN+c7SM0x4N2bvi Bf9n4auGxryq8MlSGv6iJj44GGU3H8lvD+WIegnWQwsLWGjvLWIEU+/Y0ffkjQkf 1ldv2RHAYkRN9m7X4Gz3F9xoxb+5G6QYe8Th0yt13qip8Vwt2R568SFJKGcQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:feedback-id :feedback-id:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1670350535; x=1670436935; bh=YxOc+fQckFki78WcCm77tq5zHWCF ur5uD9eIzM2tcsU=; b=MsSMwzjNtT+J93N6qiMf2VOiXxnOmx7d9+gHms00HYne BWSNGr3oNBhltvL0psopOqi0Lz7SNMmfBRK4Ap8bdFqjSFvYcjLl719zOhJV/W1A 1byjqdS9/ibkMVH3IZ5b3gw9RRI0lvLPO2REYVfFJewBw0FwwRYlmyo+MsDG9deK vBqTidwTR+0DPOjbp22IC3ooAKf4tvZ5XGFr216YdehgNHCUfW25B/peQCmFejxt OaDXNLKqu0mE7fww5h7mYgLbcIaAm65+8D0mSKwJ6qOYQZlf1BduY4bWWWiR9JnV 4NB9Epwna34OQahIUkDNHcATIug37zKOTAr+6hvTlQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudeigdduuddtucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkfhggtggujgesthdtredttddtvdenucfhrhhomheptehnughr vghsucfhrhgvuhhnugcuoegrnhgurhgvshesrghnrghrrgiivghlrdguvgeqnecuggftrf grthhtvghrnhephfegjedtudegveffteefjeeljedvgeetueelffdtffejgeffgeeggeff teegheeunecuffhomhgrihhnpegtihhrrhhushdqtghirdgtohhmnecuvehluhhsthgvrh fuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprghnughrvghssegrnhgrrhgr iigvlhdruggv X-ME-Proxy: Feedback-ID: id4a34324:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 6 Dec 2022 13:15:34 -0500 (EST) Date: Tue, 6 Dec 2022 10:15:33 -0800 From: Andres Freund To: Thomas Munro Cc: Justin Pryzby , Michael Paquier , pgsql-hackers@lists.postgresql.org, Nazir Bilal Yavuz Subject: Re: pg_upgrade test failure Message-ID: <20221206181533.pmcz75zbjgvnnzum@awork3.anarazel.de> References: <20221018043144.GF7745@telsasoft.com> <20221018162908.cb3n7tahtekypbkf@awork3.anarazel.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On 2022-11-08 01:16:09 +1300, Thomas Munro wrote: > So [1] on its own didn't fix this. My next guess is that the attached > might help. > > Hmm. Following Michael's clue that this might involve log files and > pg_ctl, I noticed one thing: pg_ctl implements > wait_for_postmaster_stop() by waiting for kill(pid, 0) to fail, and > our kill emulation does CallNamedPipe(). If the server is in the > process of exiting and the kernel is cleaning up all the handles we > didn't close, is there any reason to expect the signal pipe to be > closed after the log file? What is our plan here? This afaict is the most common "false positive" for cfbot in the last weeks. E.g.: https://api.cirrus-ci.com/v1/artifact/task/5462686092230656/testrun/build/testrun/pg_upgrade/002_pg_upgrade/log/regress_log_002_pg_upgrade ... [00:02:58.761](93.859s) ok 10 - run of pg_upgrade for new instance [00:02:58.808](0.047s) not ok 11 - pg_upgrade_output.d/ removed after pg_upgrade success [00:02:58.815](0.007s) # Failed test 'pg_upgrade_output.d/ removed after pg_upgrade success' # at C:/cirrus/src/bin/pg_upgrade/t/002_pg_upgrade.pl line 288. Michael: Why does 002_pg_upgrade.pl try to filter the list of files in pg_upgrade_output.d for files ending in .log? And why does it print those only after starting the new node? How about moving the iteration through the pg_upgrade_output.d to before the ->start and printing all the files, but only slurp_file() if the filename ends with *.log? Minor nit: It seems off to quite so many copies of $newnode->data_dir . "/pg_upgrade_output.d" particularly where the test defines $log_path, but then still builds it from scratch after (line 304). Greetings, Andres Freund