Re: No enough privileges for autovacuum worker - Mailing list pgsql-general

From Adrian Klaver
Subject Re: No enough privileges for autovacuum worker
Date
Msg-id 9c987b8d-6690-211a-2795-d33bd0de36ef@aklaver.com
Whole thread Raw
In response to Re: No enough privileges for autovacuum worker  (Андрей Сычёв <andrey.sychev@cifrasoft.com>)
List pgsql-general
On 3/25/21 1:25 AM, Андрей Сычёв wrote:
> Because   in  trigger  where  table  fpbackup.fp_vpn_data_2021w12  has
> been created there are several DDL commands:
> 
> EXECUTE 'CREATE TABLE "' || fp_schema_name || '"."' || fp_table_name || '" (LIKE '|| fp_parent_table_name || '
INCLUDINGDEFAULTS INCLUDING CONSTRAINTS INCLUDING INDEXES) WITHOUT OIDS TABLESPACE ' || fp_tablespace;
 
> 
> EXECUTE 'ALTER TABLE "' || fp_schema_name || '"."' || fp_table_name || '" OWNER TO fpbkwriter';
> 
> The  trigger was called by user "worker" that already had permission on
> USAGE  of schema dict, so table creation was successful. But after that
> the ownership of the table was moving to "fpbkwriter" that had no permission on
> USAGE of schema dict, thus the error occured.
> 
> In reality, there was no user "fpbkwriter" at the beginning. Only user
> "worker"  was  created. And when the user "fpbkwriter" was created, he  was
> not granted by enough privileges mistakenly.
> 

Alright that I understand. Still after the ALTER TABLE ... OWNER TO 
fpbkwriter, the index was running as fpbkwriter yet there where no 
errors? Did that mean the table was never queried or the index never used?


-- 
Adrian Klaver
adrian.klaver@aklaver.com



pgsql-general by date:

Previous
From: Андрей Сычёв
Date:
Subject: Re: No enough privileges for autovacuum worker
Next
From: Paul van der Linden
Date:
Subject: Re: Slow index creation