Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup command fails to drop pglogical role due to privileges on view pg_stat_statements #83

Open
vjeeva opened this issue Sep 13, 2022 · 1 comment
Assignees

Comments

@vjeeva
Copy link
Contributor

vjeeva commented Sep 13, 2022

Describe the bug
PgBelt fails to drop the pglogical role when running belt teardown --full with the following error:

ERROR:  role "pglogical" cannot be dropped because some objects depend on it
DETAIL:  privileges for view pg_stat_statements

Expected behavior
The teardown command runs without errors and doesn't stop in the middle.

Additional context
This happened with a Postgres 12 RDS database.

@vjeeva vjeeva self-assigned this Sep 13, 2022
@vjeeva
Copy link
Contributor Author

vjeeva commented Sep 13, 2022

Solution - just gotta run an extra REVOKE to get rid of the blocker:

REVOKE ALL ON pg_stat_statements FROM pglogical;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant