Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyVUf-0006jJ-Hw for pgsql-bugs@arkaria.postgresql.org; Thu, 24 Jan 2013 22:42:01 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TyVUe-00051H-OL for pgsql-bugs@arkaria.postgresql.org; Thu, 24 Jan 2013 22:42:00 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyVUd-00051B-N2 for pgsql-bugs@postgresql.org; Thu, 24 Jan 2013 22:41:59 +0000 Received: from [2404:130:0:10::40:2] (helo=mail.catalyst.net.nz) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyVUa-0002aT-Qb for pgsql-bugs@postgresql.org; Thu, 24 Jan 2013 22:41:59 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.catalyst.net.nz (Postfix) with ESMTP id 012E532B91 for ; Fri, 25 Jan 2013 11:41:53 +1300 (NZDT) X-Virus-Scanned: Debian amavisd-new at catalyst.net.nz Received: from mail.catalyst.net.nz ([127.0.0.1]) by localhost (bertrand.catalyst.net.nz [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3-toEQSjAQQR for ; Fri, 25 Jan 2013 11:41:51 +1300 (NZDT) Received: from [192.168.1.64] (122-60-64-230.jetstream.xtra.co.nz [122.60.64.230]) (Authenticated sender: mark.kirkwood) by mail.catalyst.net.nz (Postfix) with ESMTPSA id A618D3294F for ; Fri, 25 Jan 2013 11:41:51 +1300 (NZDT) Message-ID: <5101B8AF.3090307@catalyst.net.nz> Date: Fri, 25 Jan 2013 11:41:51 +1300 From: Mark Kirkwood User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 MIME-Version: 1.0 To: pgsql-bugs@postgresql.org Subject: Re: PL/R Median Busts Commit (Postgres 9.1.6 + plr 8.3.0.13 on Ubuntu 12.10 64 bit) References: <5100B6B2.8030408@catalyst.net.nz> <51014FCB.30601@joeconway.com> <5101A3DA.5080507@catalyst.net.nz> <5101A47D.6050508@catalyst.net.nz> <25545.1359062304@sss.pgh.pa.us> <5101A7D1.6040703@catalyst.net.nz> <25945.1359063403@sss.pgh.pa.us> In-Reply-To: <25945.1359063403@sss.pgh.pa.us> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 2404:130:0:10::40:2 (failed) X-Pg-Spam-Score: -1.1 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org On 25/01/13 10:36, Tom Lane wrote: > Mark Kirkwood writes: >> Doh! Yes of course, sorry for the noise. I was busy thinking that the >> issue could be tied up with sinval and plan caching (if there is any) in >> plr and got excited about seeing something in gdb...and didn't think >> carefully about why what I was seeing was not a bug at all :-( Thanks >> for clarifying! > > FWIW, presumably the failure comes from something throwing elog(ERROR) > after RecordTransactionCommit(). So what I'd try is setting a > breakpoint at errfinish and investigating what's causing the first error > call. If I have done this right, then this is the trace for the 1st message... from my wandering through the calls here it looks like a normal commit, and something goes a bit weird as SI messages are being processed... 0x00007f4e2a538425 in raise () from /lib/x86_64-linux-gnu/libc.so.6 (gdb) bt #0 0x00007f4e2a538425 in raise () from /lib/x86_64-linux-gnu/libc.so.6 #1 0x00007f4e2a53bb8b in abort () from /lib/x86_64-linux-gnu/libc.so.6 #2 0x00000000006e0a70 in errfinish (dummy=dummy@entry=0) at elog.c:523 #3 0x00000000006e3031 in elog_finish (elevel=elevel@entry=22, fmt=fmt@entry=0x714d58 "cannot abort transaction %u, it was already committed") at elog.c:1202 #4 0x0000000000481d87 in RecordTransactionAbort ( isSubXact=isSubXact@entry=0 '\000') at xact.c:1366 #5 0x0000000000481e89 in AbortTransaction () at xact.c:2272 #6 0x00000000004851c5 in AbortOutOfAnyTransaction () at xact.c:3807 #7 0x00000000006eddc9 in ShutdownPostgres (code=, arg=) at postinit.c:976 #8 0x0000000000610b7d in shmem_exit (code=code@entry=-1) at ipc.c:221 #9 0x0000000000610bf5 in proc_exit_prepare (code=-1) at ipc.c:181 #10 0x00007f4e2a53d901 in ?? () from /lib/x86_64-linux-gnu/libc.so.6 #11 0x00007f4e2a53d985 in exit () from /lib/x86_64-linux-gnu/libc.so.6 #12 0x00007f4e272b951a in ?? () from /usr/lib/libR.so #13 #14 0x00007f4e2a538707 in kill () from /lib/x86_64-linux-gnu/libc.so.6 #15 0x00000000006152e5 in SICleanupQueue ( callerHasWriteLock=callerHasWriteLock@entry=1 '\001', minFree=minFree@entry=4) at sinvaladt.c:672 #16 0x00000000006153bd in SIInsertDataEntries (data=0x3943b70, n=0) at sinvaladt.c:437 #17 0x00000000006d1371 in ProcessInvalidationMessagesMulti ( hdr=hdr@entry=0x204a280, func=0x6149f0 ) at inval.c:402 #18 0x00000000006d2020 in AtEOXact_Inval (isCommit=isCommit@entry=1 '\001') at inval.c:940 #19 0x0000000000482bdd in CommitTransaction () at xact.c:1893 #20 0x0000000000484975 in CommitTransactionCommand () at xact.c:2562 #21 0x00000000006276d3 in finish_xact_command () at postgres.c:2452 #22 finish_xact_command () at postgres.c:2441 #23 0x000000000062a6f5 in exec_simple_query (query_string=0x20e8d70 "COMMIT;") at postgres.c:1037 #24 PostgresMain (argc=, argv=argv@entry=0x20476b8, username=) at postgres.c:3968 #25 0x00000000005ee92f in BackendRun (port=0x2068f40) at postmaster.c:3617 #26 BackendStartup (port=0x2068f40) at postmaster.c:3302 #27 ServerLoop () at postmaster.c:1466 #28 0x00000000005ef4dc in PostmasterMain (argc=argc@entry=1, argv=argv@entry=0x2044640) at postmaster.c:1127 #29 0x0000000000453edb in main (argc=1, argv=0x2044640) at main.c:199 -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs