We do not currently allow superuser access to Aiven PostgreSQL services. Most of the actions typically done as a superuser can be performed in a different way in Aiven.

The default avnadmin database user has permissions to do most of the usual DB management operations, for example:

  • Managing databases (CREATE DATABASE , DROP DATABASE )
  • Creating database users (CREATE USER/ROLE , DROP USER/ROLE )
  • Creating extensions in databases (CREATE EXTENSION )
  • Managing access permissions (GRANT , REVOKE )
  • Logical replication as it has the REPLICATION privilege¬†

Databases and users can also be managed from the Aiven web console or though our REST API.

You can use the grant system to limit access to different users. Various commands, such as the TRUNCATE command do not require superuser rights at all but you'll be able to limit its use to your main user account in the DB.

A number of extensions can be installed in Aiven PostgreSQL databases without superuser access, please see the list of extensions for more information.

Also the extension aiven_extras contains additional superuser-like functionality that avnadmin can use to do things that normally require superuser privileges. Things like PostgreSQL builtin logical replication and auto_explain usage fall under this usage category.

Got here by accident? Learn how Aiven simplifies Postgres:

Did this answer your question?