# Configure High availability PostgreSQL cluster on OpenShift with the operator

**URL:** <https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807>\
**Category:** Percona Distribution for PostgreSQL\
**Created:** [July 29, 2022, 10:49am UTC](https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807 "2022-07-29T10:49:35Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Luan](https://avatars.discourse-cdn.com/v4/letter/l/b9bd4f/32.png) [@Luan](https://forums.percona.com/u/Luan)\
**Post date:** [July 29, 2022, 10:49am UTC](https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807/1 "2022-07-29T10:49:35Z")

</div>

Dear,

I have installed and created a default PostgreSQL cluster with kind “PerconaPGCluster”. My question is:  
-Is it already equipped with High availability feature? Or should I add additional config (e.g. Patroni) to achieve HA feature?

Thank you in advance!

---

<div class="post-metadata">

**Author:** ![Ege\_Gunes](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/ege_gunes/32/4595_2.png) [@Ege\_Gunes](https://forums.percona.com/u/Ege_Gunes)\
**Post date:** [July 29, 2022, 10:55am UTC](https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807/2 "2022-07-29T10:55:08Z")

</div>

Hi @Luan ,

After you deploy the `PerconaPGCluster` you don’t need to do anything for HA, Patroni is already configured and deployed by the operator. You can read more in [the docs](https://docs.percona.com/percona-operator-for-postgresql/architecture.html). Also you might be interested in [this webinar](https://learn.percona.com/high-availability-and-disaster-recovery-recipes-for-postgresql-on-kubernetes).

---

<div class="post-metadata">

**Author:** ![Luan](https://avatars.discourse-cdn.com/v4/letter/l/b9bd4f/32.png) [@Luan](https://forums.percona.com/u/Luan)\
**Post date:** [July 29, 2022, 11:05am UTC](https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807/3 "2022-07-29T11:05:34Z")

</div>

Thank you very much for your quick nice answer.

In my test, I created a cluster with default configuration. After few seconds, I see there are 1 primary pods and 2 replicas created and associated with the new cluster.

Then I connected my web application with it, and everything works well (I created some application users, then login the app with them).

Then I manually deleted the running primary Postgres pod instance. I see the database is not accessible for about **1** minute (until I see a new primary pod instance created).

Is the “1 minute” expected downtime? is that due to failing over process or is that the time for re-creating a new primary pod instance?

Thank you again!

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [July 31, 2022, 9:20pm UTC](https://forums.percona.com/t/configure-high-availability-postgresql-cluster-on-openshift-with-the-operator/16807/4 "2022-07-31T21:20:25Z")

</div>

> [@Luan](#):
>
> Is the “1 minute” expected downtime? is that due to failing over process or is that the time for re-creating a new primary pod instance?

Yes, and yes. K8S cannot “instantly” recreate a new pod with all provisioned storage etc.
