X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4631614B281A for ; Tue, 10 Aug 2004 01:35:59 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 34883-03 for ; Tue, 10 Aug 2004 04:35:57 +0000 (GMT) Received: from web13124.mail.yahoo.com (web13124.mail.yahoo.com [216.136.174.142]) by svr1.postgresql.org (Postfix) with SMTP id 8344114B280B for ; Tue, 10 Aug 2004 01:35:55 -0300 (ADT) Message-ID: <20040810043555.38371.qmail@web13124.mail.yahoo.com> Received: from [24.9.238.30] by web13124.mail.yahoo.com via HTTP; Mon, 09 Aug 2004 21:35:55 PDT Date: Mon, 9 Aug 2004 21:35:55 -0700 (PDT) From: Litao Wu Subject: Re: insert waits for delete with trigger To: Tom Lane Cc: pgsql-performance@postgresql.org In-Reply-To: <22223.1092097903@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.1 tagged_above=0.0 required=5.0 tests=RCVD_IN_SORBS X-Spam-Level: X-Archive-Number: 200408/118 X-Sequence-Number: 7754 Hi Tom, No row has granted='f'. The result shown in the original email is from: select c.relname, l.pid, l.mode, l.granted, current_query from pg_locks l, pg_class c, pg_stat_activity a where relation is not null AND l.relation = c.oid AND l.pid = a.procpid AND l.mode != 'AccessShareLock' order by l.pid; After the above result, I went to OS to get ps status. Did I miss something? Since the lock was granted to pid (18951), that cause me confuse why OS ps shows it is waiting. Also, I ntoiced that insert will be finished almost immediately after delete is done. Thanks, --- Tom Lane wrote: > Litao Wu writes: > > Here is info from pg_lock: > > All those locks are already granted, so they are not > much help in > understanding what PID 18951 is waiting for. What > row does it have > with granted = 'f' ? > > regards, tom lane > > ---------------------------(end of > broadcast)--------------------------- > TIP 7: don't forget to increase your free space map > settings > __________________________________ Do you Yahoo!? Yahoo! Mail is new and improved - Check it out! http://promotions.yahoo.com/new_mail