Received: from magus.postgresql.org ([87.238.57.229]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TGzEZ-00089S-5f for pgsql-bugs@postgresql.org; Wed, 26 Sep 2012 21:33:31 +0000 Received: from mahout.postgresql.org ([98.129.198.123]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TGzEW-0000W9-MH for pgsql-bugs@postgresql.org; Wed, 26 Sep 2012 21:33:30 +0000 Received: from [204.145.124.246] (helo=wrigleys.postgresql.org) by mahout.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TGzEV-0001X8-1w for pgsql-bugs@postgresql.org; Wed, 26 Sep 2012 21:33:27 +0000 Received: from www-data by wrigleys.postgresql.org with local (Exim 4.72) (envelope-from ) id 1TGzEU-0005zV-JC for pgsql-bugs@postgresql.org; Wed, 26 Sep 2012 21:33:26 +0000 Date: Wed, 26 Sep 2012 21:33:26 +0000 Message-Id: Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Subject: BUG #7572: virtualxid lock held by bgwriter on promoted slaves To: pgsql-bugs@postgresql.org From: daniele.varrazzo@gmail.com X-Pg-Spam-Score: -1.8 (-) X-Archive-Number: 201209/279 X-Sequence-Number: 34273 The following bug has been logged on the website: Bug reference: 7572 Logged by: Daniele Varrazzo Email address: daniele.varrazzo@gmail.com PostgreSQL version: 9.1.4 Operating system: Linux Description: = Hello, when a slave is promoted, the pgwriter keeps holding a lock with virtualxid "1/1" and virtualtransaction "-1/0". Such lock stops pg_reorg to run (as reported here: http://pgfoundry.org/tracker/index.php?func=3Ddetail&aid=3D1011203&group_id= =3D1000411&atid=3D1376) but I've verified the same condition on 9.1.4). Is it possible to free that lock on slave promotion? Is it safe to ignore that lock for pg_reorg sake? The program is which is probably waiting for all the transactions to finish before swapping the table in the system catalog but I'm not sure about that yet.