pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Andrus <kobruleht2@hot.ee>
To: pgsql-general@postgresql.org
Subject: Re: permission denied for large object 200936761
Date: Mon, 1 Feb 2021 08:58:58 -0800
Message-ID: <f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com> (raw)
In-Reply-To: <08f90e7b-8d08-d46e-abb7-85dd68bc3078@hot.ee>
References: <47c92baa-949b-92d1-c162-1f0d8348fb50@hot.ee>
	<2eee8862-ea29-3e9c-30ff-82ec7ad4d99f@aklaver.com>
	<08f90e7b-8d08-d46e-abb7-85dd68bc3078@hot.ee>

On 2/1/21 8:32 AM, Andrus wrote:
> Hi!
>>>
>>> Database does not contain large objects.
>>>
>>> pg_dump starts to throw error
>>>
>>> ERROR:  permission denied for large object 200936761
>>
>> Did you do the pg_dump as a superuser?
> 
> No.
> 
> pg_dump needs to be invoked by non-superuser also. It backs up two 
> schemas, public and firma74 .

Well the user that runs the pg_dump needs to have permissions on the 
large objects. For more information see below.

> 
> -n public -n firma74
> 
> command line options are used.
> 
>>
>> You can query that to see what is there. I would not go about deleting 
>> until you find what the large objects are for.
>>
> select * from pg_largeobject
> 
> returns empty table.


I haven't used large objects in a while. Forgot that they now have 
permissions associated with them. Try:

https://www.postgresql.org/docs/12/catalog-pg-largeobject-metadata.html

instead.


> 
> Database has approx 50 schemas and many thousands of tables.
> 
> Andrus.
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com





view thread (27+ messages)  latest in thread

Message-ID: <f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com>
Permalink:  ../f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com/
Also on:    postgresql.org/message-id/f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@aklaver.com, kobruleht2@hot.ee
  Subject: Re: permission denied for large object 200936761
  In-Reply-To: <f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com>
  References: <47c92baa-949b-92d1-c162-1f0d8348fb50@hot.ee> <2eee8862-ea29-3e9c-30ff-82ec7ad4d99f@aklaver.com> <08f90e7b-8d08-d46e-abb7-85dd68bc3078@hot.ee> <f4bf75cc-cb4a-9154-4189-2ae8e539ccf9@aklaver.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox