Thread: struggling with GRANT while upgrading from 13 to 16
Hi all, I’m getting ERROR: permission denied to grant privileges as role "axel" DETAIL: The grantor must have the ADMIN option on role "daemons". ERROR: permission denied to grant privileges as role "axel" DETAIL: The grantor must have the ADMIN option on role "daemons". ERROR: permission denied to grant privileges as role "axel" DETAIL: The grantor must have the ADMIN option on role "xtrole". ERROR: permission denied to grant privileges as role "axel" DETAIL: The grantor must have the ADMIN option on role "xtrole". while trying load a dump from 13 into 16 server. Correcting this on 13 seems impossible as new syntax/options are required. What would be the upgrade path to fix this? What would be the SQL phrase to do it ? Any help appreciated, Axel --- PGP-Key: CDE74120 ☀ mobile: +49 160 7568212 computing @ chaos claudius
On Tue, Jun 25, 2024 at 10:05 AM Axel Rau <Axel.Rau@chaos1.de> wrote:
Hi all,
I’m getting
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "daemons".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "daemons".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "xtrole".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "xtrole".
while trying load a dump from 13 into 16 server.
Correcting this on 13 seems impossible as new syntax/options are required.
What would be the upgrade path to fix this?
What would be the SQL phrase to do it ?
Is there a reason you can't grant axel those other roles as admin? Such as:
GRANT daemons TO axel WITH ADMIN OPTION;
GRANT xtrole TO axel WITH ADMIN OPTION; I may be missing something really basic, but if you do that on v16 before running the load, would that fix it? Maybe there are security implications for your setup that make this unthinkable, but if that's true, having daemons and xtrole connected to these tables / data might be a problem more generally?
Steve
Hi Steve.
Thanks a lot,
No this worked. (-:Am 25.06.2024 um 19:28 schrieb Steve Midgley <science@misuse.org>:Is there a reason you can't grant axel those other roles as admin? Such as:GRANT daemons TO axel WITH ADMIN OPTION;GRANT xtrole TO axel WITH ADMIN OPTION;
I do another dump and try to load it.
Axel
---
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
computing @ chaos claudius
Axel Rau <Axel.Rau@Chaos1.DE> writes: > I’m getting > ERROR: permission denied to grant privileges as role "axel" > DETAIL: The grantor must have the ADMIN option on role "daemons". > ERROR: permission denied to grant privileges as role "axel" > DETAIL: The grantor must have the ADMIN option on role "daemons". > ERROR: permission denied to grant privileges as role "axel" > DETAIL: The grantor must have the ADMIN option on role "xtrole". > ERROR: permission denied to grant privileges as role "axel" > DETAIL: The grantor must have the ADMIN option on role "xtrole". > while trying load a dump from 13 into 16 server. First I've heard of such a problem. Could you provide more detail on this? What are the actual roles and privileges involved? Which pg_dump version did you use? regards, tom lane
Am 25.06.2024 um 19:38 schrieb Axel Rau <Axel.Rau@chaos1.de>:No this worked. (-:GRANT daemons TO axel WITH ADMIN OPTION;GRANT xtrole TO axel WITH ADMIN OPTION;I do another dump and try to load it.
Axel
---
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
computing @ chaos claudius
Sent per privat email.Am 25.06.2024 um 20:46 schrieb Tom Lane <tgl@sss.pgh.pa.us>:First I've heard of such a problem. Could you provide more detail on
this? What are the actual roles and privileges involved?
Which
pg_dump version did you use?
$ pg_dump --version
pg_dump (PostgreSQL) 13.15
Axel
---
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
computing @ chaos claudius
Am 25.06.2024 um 20:46 schrieb Tom Lane <tgl@sss.pgh.pa.us>:Axel Rau <Axel.Rau@Chaos1.DE> writes:I’m gettingERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "daemons".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "daemons".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "xtrole".
ERROR: permission denied to grant privileges as role "axel"
DETAIL: The grantor must have the ADMIN option on role "xtrole".while trying load a dump from 13 into 16 server.
First I've heard of such a problem. Could you provide more detail on
this? What are the actual roles and privileges involved? Which
pg_dump version did you use?
Soorry for the noise and thanks to all help and hints,
Axel
---
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
PGP-Key: CDE74120 ☀ mobile: +49 160 7568212
computing @ chaos claudius