Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3EEg-0005ZK-H7 for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Apr 2018 05:11:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f3EEe-0001GZ-KU for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Apr 2018 05:11:56 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3EEe-0001GL-5h; Tue, 03 Apr 2018 05:11:56 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3EEb-000545-Hh; Tue, 03 Apr 2018 05:11:54 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id B34F321803; Tue, 3 Apr 2018 01:11:52 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Tue, 03 Apr 2018 01:11:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=erlTRr6UtFjrJjTrfUkGaByOS7yWmrGDOUo1R5phvxY=; b=CG2WsQ4u Ia+H9yuqxEz2+17tKWMINcWq+cDxPL81m49kUJzWNxJDOl0dWbqDz7oGYd+S2/m1 hV3zUpCseDyTbPGCr19gJq8smGkynHyAxFZs9mg6smfCdX/DxopcN6l86YZO8qq2 /A+r14ev75/Oo93ymBaj3w3KdywsEq6rw9fNTWWTlPWWOHcdOjNU02GnznNlfL3m N9ddzgaA9GFfdNuOjxqDj8Mj2bKBJa59TvkjJxAffOUKrvv0URZajrl4ettqffvU 8ZnJrF/VHU1m0c8hzkUqBxpB5ao+c8HaDeZdbr1rWQ5VWAz1JrUf1Fz3PwfKtNWl GyA38NJ3tVukxg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=erlTRr6UtFjrJjTrfUkGaByOS7yWm rGDOUo1R5phvxY=; b=jpRiqRBgkUbvuG16xLXhFymejJmUB5mi/tqD+F9/gc7ir Bq+G4ZOKrI/AF+FLgenguctY6KBWYgoCDXGrr0uY/8/lijh2kcJhmVY/HE9PVVI5 iEnw740l5MPUZ/s4JObWSZSBPXk2KwrX5mnBZidOOTLv6fik0y3tqLphfh1RHQeO cDzLOvP+205uzM8Zgw2FhB4WuedW3Cir0Atp3Vebqp5IDBDWOrTmnd3DGuiTKbu1 NYWbSymV+/7T3fTKo4PKtQHJsc041i/b5J+bq1CjNrfKGCfdjxUztUTtD6LhDyfP kMUx/IUQLNJUvWyn0Va+fs4MdIn7lpizE97P3wDQg== X-ME-Sender: Received: from paquier.xyz (c137162.net61215.cablenet.ne.jp [61.215.137.162]) by mail.messagingengine.com (Postfix) with ESMTPA id 6D65B10291; Tue, 3 Apr 2018 01:11:49 -0400 (EDT) Date: Tue, 3 Apr 2018 14:11:46 +0900 From: Michael Paquier To: Andres Freund Cc: "Bossart, Nathan" , Masahiko Sawada , Robert Haas , Lyes Ameddah , Tomas Vondra , "pgsql-hackers@postgresql.org" , "pgsql-bugs@postgresql.org" Subject: Re: BUG #14941: Vacuum crashes Message-ID: <20180403051146.GA12320@paquier.xyz> References: <4B232BD7-A97D-4461-81E6-28A49764B60E@amazon.com> <20180110025331.GE336@paquier.xyz> <20180110231442.GA22983@paquier.xyz> <20180304001252.5sxn3glccnu5qxjm@alap3.anarazel.de> <7327B413-1A57-477F-A6A0-6FD80CB5482D@amazon.com> <20180307050345.GA3095@paquier.xyz> <3834EFB8-2A90-41C7-A7C8-8B956150479D@amazon.com> <4D1115BF-ED38-44E2-B799-C7F9E421A3B8@amazon.com> <20180331001946.uie7elezusxes7qw@alap3.anarazel.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="pWyiEgJYm5f9v55/" Content-Disposition: inline In-Reply-To: <20180331001946.uie7elezusxes7qw@alap3.anarazel.de> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --pWyiEgJYm5f9v55/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Mar 30, 2018 at 05:19:46PM -0700, Andres Freund wrote: > On 2018-03-30 18:39:01 +0000, Bossart, Nathan wrote: >> I think the most straightforward approach for fixing this is to add >> skip-locked functionality in find_all_inheritors(), >> find_inheritance_children(), and vac_open_indexes(), but I am curious >> what others think. For vac_open_indexes() it may make the most sense to introduce a new try_open_index which wraps on top of try_relation_open with checks on the opened relation's relkind.=20 > I'm actually wondering if we shouldn't just ignore this problem. While > the other cases VACUUM (SKIP LOCKED) are intended to solve seem common, > these seem less so. But it'd be a bit weird, too.. Wouldn't that cause deadlocks if one session has VACUUM (SKIP_LOCKED) and another session running vacuum or autovacuum if simply ignored? That looks dangerous to me than simply skipping a lock that cannot be taken. -- Michael --pWyiEgJYm5f9v55/ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAlrDDRIACgkQnvQgOdby QH1jaQ/9ENnx4SMRCTaVqsePCW9L/Q0Mxr3RmLS9cWkjPMqmnyqxx2M4dVTbEyfK VCh64+ZuTck6USHUtGGJ7/HmYuQXMvLerNpVojeccrg47W50JMhjiuPsIE7vfwiN bZLhMsKF1RkpP4OwNkQJq9u+XUMSb8dbBH1N+wE9ghPezqVXhI5tb9JFIq3NGV8F 5V5f5aUbOpp+FMUtz5gwm/eqiLR2Z39qYTMWFA20kMVL2iSzHPOPqe6WaGnifiAV iaRv2HeOKu6Uj0dxSAasRLJfhNAiXga1344R8jvsDpzWFyEWNnaR73fsBeT9oP/q jZz2UF1RJ7FYlOQM78e6mvwx0wbecCphs1R0/lWKuLm5h3GNp9c3twPN69NVDw7y +VwAffSh5RZmIO/MRhPEeODj5s1TcmqVfKxHB/Xqi177wuI2uzmNP2oRKeR24zJB /oZ5hJy1Z1b5W2DzoWDVethNwviXk11vSAVRVW8cgOSaaPEhdpo3fAliSKHTN+vz oc1TJaCw1Tm2BwRt0A5fA1gfpGup6MGnAFfyk/ivOukNry8W49DCD/cAA5CWAvIf YglPrsPch4Ax+/asHtn0OMypnkdynB8YVZHjArWEESX0UcB2+YsiTckuLboP5Qby zgQZcA1lbv/eO/4Z/Ara4JfxPvVQuDC9e5YZUlARn9I37AiZPWY= =oAVL -----END PGP SIGNATURE----- --pWyiEgJYm5f9v55/--