2020-07-28 23:09:34 +05:30
---
2022-07-23 23:45:48 +05:30
stage: Data Stores
2021-01-03 14:25:43 +05:30
group: Database
2022-11-25 23:54:43 +05:30
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments
2020-07-28 23:09:34 +05:30
---
2021-12-11 22:18:48 +05:30
# Configuring PostgreSQL for scaling **(FREE SELF)**
2020-07-28 23:09:34 +05:30
2022-07-23 23:45:48 +05:30
In this section, you are guided through configuring a PostgreSQL database to
2021-01-03 14:25:43 +05:30
be used with GitLab in one of our [reference architectures ](../reference_architectures/index.md ).
2020-07-28 23:09:34 +05:30
2023-04-23 21:23:45 +05:30
## Configuration options
Choose one of the following PostgreSQL configuration options:
### Standalone PostgreSQL using Omnibus GitLab
2020-07-28 23:09:34 +05:30
This setup is for when you have installed the
[Omnibus GitLab packages ](https://about.gitlab.com/install/ ) (CE or EE),
to use the bundled PostgreSQL having only its service enabled.
2023-04-23 21:23:45 +05:30
Read how to [set up a standalone PostgreSQL instance ](standalone.md ) using Omnibus GitLab.
2020-07-28 23:09:34 +05:30
2023-04-23 21:23:45 +05:30
### Provide your own PostgreSQL instance
2020-07-28 23:09:34 +05:30
This setup is for when you have installed GitLab using the
[Omnibus GitLab packages ](https://about.gitlab.com/install/ ) (CE or EE),
or installed it [from source ](../../install/installation.md ), but you want to use
your own external PostgreSQL server.
2023-04-23 21:23:45 +05:30
Read how to [set up an external PostgreSQL instance ](external.md ).
2021-12-11 22:18:48 +05:30
2023-04-23 21:23:45 +05:30
### PostgreSQL replication and failover with Omnibus GitLab **(PREMIUM SELF)**
2021-12-11 22:18:48 +05:30
This setup is for when you have installed GitLab using the
[Omnibus GitLab **Enterprise Edition** (EE) package ](https://about.gitlab.com/install/?version=ee ).
All the tools that are needed like PostgreSQL, PgBouncer, and Patroni are bundled in
the package, so you can use it to set up the whole PostgreSQL infrastructure (primary, replica).
2023-04-23 21:23:45 +05:30
Read how to [set up PostgreSQL replication and failover ](replication_and_failover.md ) using Omnibus GitLab.
## Related topics
- [Working with the bundled PgBouncer service ](pgbouncer.md )
- [Database load balancing ](database_load_balancing.md )
- [Moving GitLab databases to a different PostgreSQL instance ](moving.md )
- [Multiple databases ](multiple_databases.md )
- [Database guides for GitLab development ](../../development/database/index.md )