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 1iwjWg-0007wt-Ui for pgsql-bugs@arkaria.postgresql.org; Wed, 29 Jan 2020 09:20:47 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iwjWd-0008K5-EE for pgsql-bugs@arkaria.postgresql.org; Wed, 29 Jan 2020 09:20:43 +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 1iwjWc-0008Jx-3F for pgsql-bugs@lists.postgresql.org; Wed, 29 Jan 2020 09:20:43 +0000 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1iwjWX-0001fv-9S for pgsql-bugs@lists.postgresql.org; Wed, 29 Jan 2020 09:20:40 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.west.internal (Postfix) with ESMTP id D167C695; Wed, 29 Jan 2020 04:20:34 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Wed, 29 Jan 2020 04:20:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hintbits.com; h= content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=mesmtp; bh=/1yRX3Ox49rNqYLfO4tr/1Aqk6tHOtHVvMr19aBEaSk=; b=D1iPzlHCnStw hBH8eE6UJLUl43OyxVpTk5dpIe1oiCFuOZw/gLecjzd4W0K5JeSwuBuXAD8P9sNS IfyoMM9FgLYs4RCoQVU827vA08bTh3AKQBWw94YF2v4N7rD2nvES3fGYj3tNGzGP ifHILT7pudTwGgxt7/SKFRJYieeP2b4= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=/1yRX3Ox49rNqYLfO4tr/1Aqk6tHOtHVvMr19aBEa Sk=; b=yKun/yF/qvhN4IXB8jscFUMuwTBiNUhmOPoqFMhvwnCCLC8xCfsV14fxz WVvffGfkupYKZAkCKEnpJUfN3qNWD/JYMxY8co/cTZKpdMRmYGnURzf8Kp9bpZi2 Nap3QJftab28IAq86g6WnaKBZtt5ECrlB+kvqs3g1uFBu8BIRxEgKQK7kKPgztHb zyJZuX08GFwDdVMKK/i++wu3a1VguBboP6PFaA6U2Di7bAw8RzJ/HWVU6s2mtnsY N4QP1Tc4UWC+V9U5j8/nULJMaMURb2U2g1O1whFQ6uS0qCUnzd6zc5AkdK2D3buf AarDkjtK6KDnV6mHZsyD+fOCnG9fw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrfeeigddtudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpegtggfuhfgjfffgkfhfvffosehtqhhmtdhhtdejnecuhfhrohhmpefqlhgvkhhs ihhiucfmlhhiuhhkihhnuceorghlvgigkheshhhinhhtsghithhsrdgtohhmqeenucfkph epudejkedrudehrddufeekrddugeeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghr rghmpehmrghilhhfrhhomheprghlvgigkheshhhinhhtsghithhsrdgtohhm X-ME-Proxy: Received: from [192.168.8.55] (office.adjust.com [178.15.138.146]) by mail.messagingengine.com (Postfix) with ESMTPA id DDF563060C1B; Wed, 29 Jan 2020 04:20:32 -0500 (EST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3608.40.2.2.4\)) Subject: Re: postgres crash on concurrent update of inheritance partitioned table From: Oleksii Kliukin In-Reply-To: <29583.1580250599@sss.pgh.pa.us> Date: Wed, 29 Jan 2020 10:20:30 +0100 Cc: Tomas Vondra , Andres Freund , pgsql-bugs@lists.postgresql.org, ildus@adjust.com, Chris Travers , Nick Babadzhanian , julian.schauder@gmx.de Content-Transfer-Encoding: quoted-printable Message-Id: References: <20200128170755.bq3f27bfkjpt4d4b@development> <29583.1580250599@sss.pgh.pa.us> To: Tom Lane X-Mailer: Apple Mail (2.3608.40.2.2.4) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Tom Lane wrote: > Tomas Vondra writes: >> On Tue, Jan 28, 2020 at 05:17:14PM +0100, Oleksii Kliukin wrote: >>> We have experienced a few crashes a day since upgrading to pg 12.1 = last >>> week, during the process of updating an inheritance-partitioned = table by >>> several concurrent sessions. >=20 >> Yeah, I can reproduce it too. If I had to guess, I'd say it's another >> bug due to=20 >> commit 3fb307bc4a76815f96fec28a0d1525ab3fbbcfb4 >> Author: Andres Freund >> Date: Mon Sep 9 05:21:30 2019 -0700 >> Reorder EPQ work, to fix rowmark related bugs and improve = efficiency. >> which introduced relsubs_done et al, and perhaps did not get the life >> cycle / resetting right. Not sure. >=20 > Yup, that's it exactly. EvalPlanQualStart was expecting to reuse > relsubs_rowmark and relsubs_done, but that storage will be recycled by > EvalPlanQualEnd because it's in the query context of the = recheckestate. > AFAICS the re-use has no semantic value, so I just got rid of it. Sounds good, thank you! Regards, Oleksii =E2=80=9CAlex=E2=80=9D Kliukin=