X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id F12F59DC87B for ; Sat, 18 Mar 2006 02:49:14 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 34161-03 for ; Sat, 18 Mar 2006 02:49:14 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 788C39DCA31 for ; Sat, 18 Mar 2006 02:49:12 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id k2I6nCxd013785; Sat, 18 Mar 2006 01:49:12 -0500 (EST) To: Kevin Brown cc: pgsql-general@postgresql.org Subject: Re: Transactions In-reply-to: <200603180045.44743.blargity@gmail.com> References: <200603180020.01418.blargity@gmail.com> <13508.1142662755@sss.pgh.pa.us> <200603180045.44743.blargity@gmail.com> Comments: In-reply-to Kevin Brown message dated "Sat, 18 Mar 2006 00:45:44 -0600" Date: Sat, 18 Mar 2006 01:49:12 -0500 Message-ID: <13784.1142664552@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.113 required=5 tests=[AWL=0.113] X-Spam-Score: 0.113 X-Spam-Level: X-Archive-Number: 200603/809 X-Sequence-Number: 92674 Kevin Brown writes: > When the "deadlock" occurs: > kevin@ajbit:~> ps -elF | grep postgres > 1 S postgres 6020 17767 0 75 0 - 10585 - 15136 0 19:57 ? > 00:00:29 postgres: dli dli 127.0.0.1(39869) idle in transaction > 1 S postgres 6195 17767 0 76 0 - 10323 semtim 14940 0 20:22 ? > 00:00:28 postgres: dli dli 127.0.0.1(37735) INSERT waiting > You can see an insert is just waiting. On what? I'd bet it's waiting on the "idle in transaction" transaction, which is waiting for a nonresponding client. But the pg_locks view would tell you more. regards, tom lane