Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Y9eLo-0007AS-64 for pgsql-bugs@arkaria.postgresql.org; Fri, 09 Jan 2015 18:32:00 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1Y9eLm-0007Nh-RH for pgsql-bugs@arkaria.postgresql.org; Fri, 09 Jan 2015 18:31:58 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1Y9eLl-0007Na-QQ for pgsql-bugs@postgresql.org; Fri, 09 Jan 2015 18:31:57 +0000 Received: from janus.meme.com ([69.17.73.118] helo=smtp.meme.com) by makus.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1Y9eLi-0005ry-BY for pgsql-bugs@postgresql.org; Fri, 09 Jan 2015 18:31:55 +0000 Received: from slate.meme.com (unknown [192.168.1.14]) by smtp.meme.com (Postfix) with ESMTPS id 4B0E9A0F0; Fri, 9 Jan 2015 12:31:49 -0600 (CST) Received: from slate.meme.com (localhost [IPv6:::1]) by slate.meme.com (Postfix) with ESMTP id CB26A3FB6A; Fri, 9 Jan 2015 12:31:48 -0600 (CST) Date: Fri, 9 Jan 2015 12:31:46 -0600 From: "Karl O. Pinc" To: Kevin Grittner Cc: "pgsql-bugs@postgresql.org" Subject: Re: BUG #12469: pg_locks shows locks held by pids not found i n pg_stat_activity or ps Message-ID: <20150109123146.600a392c@slate.meme.com> In-Reply-To: <1511260135.4208486.1420826855952.JavaMail.yahoo@jws10056.mail.ne1.yahoo.com> References: <20150109173951.2583.26210@wrigleys.postgresql.org> <1511260135.4208486.1420826855952.JavaMail.yahoo@jws10056.mail.ne1.yahoo.com> X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.10; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -0.2 (/) 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 Fri, 9 Jan 2015 18:07:35 +0000 (UTC) Kevin Grittner wrote: > "kop@meme.com" wrote: > > > I found that after running a large transaction (for days, it's still > > running) and then running out of shared memory that pg_locks > > reports locks held by pids that do not seem to exist, either in ps > > output or in pg_stat_activity. > > That is not a bug. For details see either of the below links: > > http://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/backend/storage/lmgr/README-SSI;hb=master > > http://vldb.org/pvldb/vol5/p1850_danrkports_vldb2012.pdf > > The short explanation is that SIReadLocks on a serializable > transaction may need to be kept until overlapping transactions > terminate. Ok. Thanks. The transactions/locks are in separate databases. I would think that in most cases that a transaction in one database cannot have any effect on a transaction in another database. It would be nice if pg were clever enough to isolate transactions within databases. Regards, Karl Free Software: "You don't pay back, you pay forward." -- Robert A. Heinlein -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs