Re: permission denied for large object 200936761

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Andrus <kobruleht2(at)hot(dot)ee>, pgsql-general(at)postgresql(dot)org
Subject: Re: permission denied for large object 200936761
Date: 2021-02-01 16:15:51
Message-ID: 2eee8862-ea29-3e9c-30ff-82ec7ad4d99f@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 2/1/21 6:43 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?

More below.

>
> Tried
>
> select * from "200936761"
>
> but it returned "relation does not exist"
>
> How to fix this ? How to find which table causes this error ?

Large objects are stored in a system catalog(table):

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

You can query that to see what is there. I would not go about deleting
until you find what the large objects are for.

>
> How to find and delete all large objects in database ? Maybe it is
> created accidently .
>
> Using
>
>  PostgreSQL 12.2 (Debian 12.2-2.pgdg100+1) on x86_64-pc-linux-gnu,
> compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
>
> Andrus.
>

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andrus 2021-02-01 16:32:54 Re: permission denied for large object 200936761
Previous Message Tom Lane 2021-02-01 14:55:22 Re: libpq and mysterious "invalid byte sequence for encoding UTF8".