GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • pgAdmin
  • Features
  • Docs
  • Version 9.19
  • Version 9.18
  • Version 9.17
  • Development
  • Community
  • Development
  • Download
  • index
  • next
  • previous
  • External database for pgAdmin user settings

This view

  • Original page
  • New address

GeezerVison is showing www.pgadmin.org — External database for pgAdmin user settings — pgAdmin 4 9.19 documentation

This page in other versions: Latest (9.19) | 9.18 | 9.17 | Development

Warning: this documentation is for a pre-release version of pgAdmin 4.

Contents
  • External database for pgAdmin user settings
    • Use SQLite Database
    • Use External Database
    • Use PostgreSQL Database
  • Getting Started
  • External database for pgAdmin user settings
    • Use SQLite Database
    • Use External Database
    • Use PostgreSQL Database
  • Connecting To A Server
  • Managing Cluster Objects
  • Managing Database Objects
  • Creating or Modifying a Table
  • Management Basics
  • Backup and Restore
  • Developer Tools
  • Processes
  • pgAgent
  • pgTimeTable Chains
  • pgAdmin Project Contributions
  • Release Notes
  • Licence

External database for pgAdmin user settings¶

The user settings used by pgAdmin are stored in a SQLite database. In this database, many settings are stored, such as preferences, user accounts, auto-discovered servers, and many more.

As SQLite is a file-based database and it can be anywhere in the file system, so it is not designed to take care of failures (no HA support). Furthermore, it isn’t designed to handle multiple connections concurrently reading/writing data to it. Example: In environments such as Kubernetes it may be useful to use an alternate backend to avoid using SQLite on non-ephemeral storage and to allow HA of the settings database.

In order to prevent this, pgAdmin now supports storing user settings in an external database using the new ‘CONFIG_DATABASE_URI’ parameter in the config.py file.

Use SQLite Database¶

In order to use SQLite Database, make sure CONFIG_DATABASE_URI parameter is set to an empty string like ‘’. By default it is set to an empty string in the config.py so if you would like to use SQLite database then no need to change anything.

Use External Database¶

In order to use an external database, make sure CONFIG_DATABASE_URI parameter is set like “dialect+driver://username:password@host:port/database”.

Note It is recommended to create the database in advance.

Use PostgreSQL Database¶

Following are the formats to use PostgreSQL as an external database.

Basic syntax:

postgresql://username:password@host:port/database

Using specific schema (It is recommended to create the schema in advance):

postgresql://username:password@host:port/database?options=-csearch_path=<schema name>

Using default pgpass path for the service account:

postgresql://username@host:port?options=-csearch_path=<schema name>

Specifying pgpass file path:

postgresql://username@host:port?passfile=<path of the pgpass file>&options=-csearch_path=<schema name>
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.