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 1f9GVG-0002ib-19 for pgsql-hackers@arkaria.postgresql.org; Thu, 19 Apr 2018 20:50:02 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f9GVD-0008Mc-O1 for pgsql-hackers@arkaria.postgresql.org; Thu, 19 Apr 2018 20:49:59 +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 1f9GVC-0008ML-EA for pgsql-hackers@lists.postgresql.org; Thu, 19 Apr 2018 20:49:59 +0000 Received: from new2-smtp.messagingengine.com ([66.111.4.224]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f9GV5-0006Y7-EK for pgsql-hackers@lists.postgresql.org; Thu, 19 Apr 2018 20:49:57 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.nyi.internal (Postfix) with ESMTP id 537F81148; Thu, 19 Apr 2018 16:49:50 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Thu, 19 Apr 2018 16:49:50 -0400 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:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=0gy5i0vh+sFYeH3zX csJZkALw+fLHqRglUPw5tmECvA=; b=EdkRUcxdn1Hs3cltM6kzJOETiqhNhyUs3 NTPYh5f+OfJSadKtE3CrLZIHqxtTjmSNHN/Iq1mOidvz0pr2uNgDsTGFFT3+vijB KSFVGlpG5krQluyc+5L/pi4IxIDbBUcX5s22ZC2yaxDuO9xC/rwwOD8fDEEyHfwp uY+ptEc5foFspH/HGQfI/9QUncnGywUBojxMUVPtJ4m1qPTGyztM+WQ+LJavzUD4 DnmnhzCbq8qQyFhC3vUy8vYm6MlShwzMnfQQhYH01i/1xe3dZjQIPlEBO8TZ1hak XUw53DXG8EQh7s5C1zmRCPaJRqEnq0xsI3jResRMqOTcf3XKJtRPw== X-ME-Sender: Received: from alvin.alvh.no-ip.org (unknown [179.56.29.253]) by mail.messagingengine.com (Postfix) with ESMTPA id 2E8EC10263; Thu, 19 Apr 2018 16:49:49 -0400 (EDT) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id C3FAB6B0; Thu, 19 Apr 2018 17:49:46 -0300 (-03) Date: Thu, 19 Apr 2018 17:49:46 -0300 From: Alvaro Herrera To: Tom Lane Cc: pgsql-hackers@lists.postgresql.org Subject: Re: Repeated crashes in GENERATED ... AS IDENTITY tests Message-ID: <20180419204946.5ujino6w4dy7biuc@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <5767.1523995174@sss.pgh.pa.us> User-Agent: NeoMutt/20170306-137-4415bd-dirty (1.8.0) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Tom Lane wrote: > The test case that's failing, in identity.sql, has been there since > early February; the lack of any crashes till more recently suggests > that something committed in mid-to-late March broke it. > > I have no idea what's going on there, but I think this is clearly > something we need to consider an open item for PG11. I'll put it > on the list. Grumble. Of the machines you listed, conchuela has gdb installed, which gives us a nice backtrace of the crash, pasted below, which seems to blame event triggers. Of the tests in the same parallel group as identity, the test fast_default seems to be the only one with an event trigger and was added on March 28th by 16828d5c0273. That combination seems to explain why the crashes appeared late ... I can't look further into this now -- maybe next week if nobody has beaten me into it. My guess is that the identity stuff is not setting state like event triggers expect. https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=conchuela&dt=2018-04-03%2010%3A00%3A00 ================== stack trace: pgsql.build/src/test/regress/tmp_check/data/postgres.core ================== [New
] Core was generated by `postgres'. Program terminated with signal 11, Segmentation fault. #0 EventTriggerTableRewrite (parsetree=parsetree@entry=0x80a852670, tableOid=49861, reason=2) at event_trigger.c:974 974 currentEventTriggerState->table_rewrite_oid = tableOid; #0 EventTriggerTableRewrite (parsetree=parsetree@entry=0x80a852670, tableOid=49861, reason=2) at event_trigger.c:974 #1 0x0000000000601bfc in ATRewriteTables (lockmode=8, wqueue=0x7fffffffe3d8, parsetree=0x80a852670) at tablecmds.c:4326 #2 ATController (parsetree=parsetree@entry=0x80a852670, rel=, cmds=, recurse=, lockmode=lockmode@entry=8) at tablecmds.c:3536 #3 0x00000000006021af in AlterTable (relid=relid@entry=49861, lockmode=lockmode@entry=8, stmt=stmt@entry=0x80a852670) at tablecmds.c:3206 #4 0x000000000077df9f in ProcessUtilitySlow (pstate=pstate@entry=0x80a852118, pstmt=pstmt@entry=0x801647110, queryString=queryString@entry=0x801646118 "ALTER TABLE itest13 ADD COLUMN b int GENERATED BY DEFAULT AS IDENTITY;", context=context@entry=PROCESS_UTILITY_TOPLEVEL, params=params@entry=0x0, queryEnv=queryEnv@entry=0x0, completionTag=0x7fffffffe830 "", dest=0x801647400) at utility.c:1116 #5 0x000000000077c632 in standard_ProcessUtility (pstmt=0x801647110, queryString=0x801646118 "ALTER TABLE itest13 ADD COLUMN b int GENERATED BY DEFAULT AS IDENTITY;", context=PROCESS_UTILITY_TOPLEVEL, params=0x0, queryEnv=0x0, dest=0x801647400, completionTag=0x7fffffffe830 "") at utility.c:919 #6 0x0000000000779e05 in PortalRunUtility (portal=0x80a60c118, pstmt=0x801647110, isTopLevel=, setHoldSnapshot=, dest=0x801647400, completionTag=0x7fffffffe830 "") at pquery.c:1183 #7 0x000000000077a925 in PortalRunMulti (portal=portal@entry=0x80a60c118, isTopLevel=isTopLevel@entry=true, setHoldSnapshot=setHoldSnapshot@entry=false, dest=dest@entry=0x801647400, altdest=altdest@entry=0x801647400, completionTag=completionTag@entry=0x7fffffffe830 "") at pquery.c:1336 #8 0x000000000077b5be in PortalRun (portal=portal@entry=0x80a60c118, count=count@entry=9223372036854775807, isTopLevel=isTopLevel@entry=true, run_once=run_once@entry=true, dest=dest@entry=0x801647400, altdest=altdest@entry=0x801647400, completionTag=0x7fffffffe830 "") at pquery.c:804 #9 0x00000000007771e5 in exec_simple_query (query_string=0x801646118 "ALTER TABLE itest13 ADD COLUMN b int GENERATED BY DEFAULT AS IDENTITY;") at postgres.c:1121 #10 0x000000000077869b in PostgresMain (argc=, argv=argv@entry=0x8012f03e8, dbname=0x8012f0190 "regression", username=) at postgres.c:4149 #11 0x0000000000480398 in BackendRun (port=0x8016c0280) at postmaster.c:4409 #12 BackendStartup (port=0x8016c0280) at postmaster.c:4081 #13 ServerLoop () at postmaster.c:1754 #14 0x0000000000701009 in PostmasterMain (argc=argc@entry=8, argv=argv@entry=0x7ffffffff5d0) at postmaster.c:1362 #15 0x0000000000481978 in main (argc=8, argv=0x7ffffffff5d0) at main.c:228 -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services