X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 1D5F49F9C18 for ; Fri, 5 May 2006 22:58:06 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 60728-02 for ; Fri, 5 May 2006 22:57:49 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mx1.surnet.cl (mx1.surnet.cl [216.155.73.180]) by postgresql.org (Postfix) with ESMTP id CA71C9F9806 for ; Fri, 5 May 2006 22:57:48 -0300 (ADT) Received: from unknown (HELO cluster.surnet.cl) ([216.155.73.165]) by mx1.surnet.cl with ESMTP; 05 May 2006 21:57:47 -0400 X-IronPort-AV: i="4.05,94,1146456000"; d="scan'208"; a="61068958:sNHT17865432" Received: from alvh.no-ip.org (201.220.122.210) by cluster.surnet.cl (7.0.043) (authenticated as alvherre@surnet.cl) id 443B7DDC00375150; Fri, 5 May 2006 21:57:45 -0400 Received: by alvh.no-ip.org (Postfix, from userid 1000) id BBA95C31DD1; Fri, 5 May 2006 21:57:42 -0400 (CLT) Date: Fri, 5 May 2006 21:57:42 -0400 From: Alvaro Herrera To: kynn@panix.com Cc: pgsql-admin@postgresql.org Subject: Re: Permission denied: LOCK TABLE test.__proc IN ACCESS SHARE MODE Message-ID: <20060506015742.GG12810@surnet.cl> Mail-Followup-To: kynn@panix.com, pgsql-admin@postgresql.org References: <200605060144.k461i8S04751@panix3.panix.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200605060144.k461i8S04751@panix3.panix.com> User-Agent: Mutt/1.5.11+cvs20060403 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200605/61 X-Sequence-Number: 21593 kynn@panix.com wrote: > pg_dump: SQL command failed > pg_dump: Error message from server: ERROR: permission denied for schema test > pg_dump: The command was: LOCK TABLE test.__proc IN ACCESS SHARE MODE > > I can't find out what transaction is responsible for this lock. When > I look at the pg_locks table, I see only two locks, and they both seem > to be due to the fact that I am interacting with psql at the moment, > and this interaction is in no way directed to the database I'm trying > to dump. You are assuming that the problem is that there is a lock conflict. This is not the case; you'd not get an error message (unless the command had specified NOWAIT). The problem here seems to be that you are trying to dump a schema or table that the dumping user has no access to. You may either grant those permissions, or create the dump with another user. -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support