PostgreSQL high availability

PostgreSQL does not fail over on its own. This page covers the replication, failover tooling and tests that make a self-hosted PostgreSQL HA design work, and what to decide before building it.

On this page

What PostgreSQL high availability requires before you build it

PostgreSQL high availability is three things working together: streaming replication to one or more standbys, an external failover manager that detects a failed primary and promotes a standby, and switchover and failover procedures that your team has run and tested. PostgreSQL provides the replication part. It supports hot standby servers that serve read-only queries, and it offers both synchronous replication, where a commit waits for standbys, and asynchronous replication. It does not detect a failed primary or notify a standby on its own, so the detection, promotion and client routing work falls to you and to the tools you choose.

Before you build anything, settle how the old primary will be fenced. If a primary becomes unreachable but keeps running, and a standby is promoted, two nodes may accept writes at once. That split-brain state can corrupt data in ways that are hard to untangle. Your design needs a clear rule for stopping the old primary, whether through power control, network isolation or a lease mechanism, and that rule must work when the node cannot be reached. Also decide how applications find the new primary, through a virtual address, DNS record or connection router, and how they handle dropped sessions and retries. Many outages last longer because clients keep pointing at the old node.

Replication mode is a business decision as much as a technical one. With asynchronous replication, a standby can trail the primary, so committed transactions that have not yet reached the standby can be lost during an unplanned failover. With synchronous replication, commits wait for acknowledgments, which adds latency and can stall writes if standbys become unavailable. Measure replication lag under your real write load, not an idle test system, and decide in writing how much data loss is acceptable and how many standbys must acknowledge. Confirm the exact synchronous settings and their behavior in the PostgreSQL high availability documentation for the version you run.

A planned switchover and an unplanned failover are different procedures with different risks. A switchover is controlled: you stop writes, confirm the standby is caught up, promote it and turn the old primary into a standby. An unplanned failover starts from a node that has already failed, may leave unreplicated transactions behind, and often requires rebuilding the former primary before it can rejoin. Test both paths on a regular schedule, time them and record what the application experienced. Backup and point-in-time recovery, connection pooling, major upgrades and security hardening all affect this design, but each has its own planning, so treat them as dependencies to address in their own work.

Components that make up a PostgreSQL HA cluster

A PostgreSQL high availability cluster is several cooperating parts, each with a defined role during failover. Some parts come from PostgreSQL itself, while failure detection and client routing come from components your team selects, configures and tests.

Primary server

The primary accepts all writes and generates the write-ahead log (WAL) that standbys replay. During failover, the failover tooling must confirm the old primary is down or fenced before any standby is promoted, which prevents two nodes from accepting writes. Configure streaming replication on the primary, create a dedicated replication role with only the privileges it needs, and limit the pg_hba.conf entries for replication to known standby addresses. Check that the failover manager records the correct host as the primary.

Hot standby servers

Hot standbys replay WAL from the primary and can serve read-only queries while they stay in sync. At failover, one standby is promoted, and the choice depends on replication lag and the priority rules in your failover manager. Enable hot standby on each standby, size every standby to run as the primary, and test that read-only workloads behave correctly on them. Read traffic sent to a standby may show slightly older data than the primary.

Synchronous or asynchronous replication

The replication mode determines how much committed data a failover can lose. With synchronous replication, a commit waits until the configured standbys confirm they received it, which protects committed transactions but adds write latency. With asynchronous replication, commits do not wait, so the most recent transactions on the primary may be missing from the promoted standby. Choose the mode per workload, set synchronous_standby_names deliberately, and agree the acceptable data loss with the business owner in writing.

WAL shipping and replication slots

Standbys receive WAL from the primary over the streaming replication connection, and archived WAL can be used to rebuild a standby after a long outage. A replication slot tells the primary to retain WAL until a specific standby has consumed it, which helps a lagging standby catch up without a full rebuild. An abandoned or lagging slot can, however, fill the primary's disk. Monitor slot lag and retained WAL volume, and assign an owner who removes unused slots.

External failover manager

PostgreSQL does not supply failure detection or automatic promotion, so the failover manager is a separate component your team selects, installs and tests. It watches the primary, decides when a failure is confirmed, promotes a standby and reconfigures the remaining nodes. Confirm with your platform team which failover manager and version they support, because this page does not name one. Configure its quorum, fencing and promotion rules, then test failover and switchover on a schedule.

Client-side routing layer

Applications must reach the current primary after a failover without manual changes to connection settings. A routing layer, such as a virtual IP, a DNS record updated by the failover tooling, or a connection proxy, sends writes to the primary and can direct read-only traffic to standbys. Each option has its own failure modes, including stale DNS caches and client sessions that stay connected to the former primary. Agree the approach with your application teams and test how clients reconnect during a failover.

Decisions that set your HA design: replication mode, standby count and failover tooling

This table compares the main choices for a PostgreSQL HA design and what each one costs you to operate. Read each row against your recovery objectives and your team's operating model, then confirm latency and lag numbers in your own environment before deciding.

OptionWhen it fitsWhat it costs you operationally
Asynchronous standbyCommit latency matters most and some data loss on failover is acceptable under your recovery objectivesTransactions committed on the primary but not yet received by the standby can be lost on failover. Monitor replication lag continuously and measure it under your peak write load.
Synchronous standbyZero data loss for committed transactions is required and the standby sits close enough to keep commit latency acceptableEvery commit waits for the standby, so standby availability and network health directly affect write availability. Plan how the primary behaves when the standby is slow or unreachable, and measure commit latency in your environment.
Quorum-based synchronous standbysYou run several standbys and want a commit acknowledged by a set number of them rather than one named standbyAdds configuration to keep current (which standbys count and how many must confirm). Failover logic must choose a candidate with the most recent data, and you need to test that choice. Confirm the exact settings against the PostgreSQL high availability documentation for your version.
Standby in a second siteA site-level failure must be survivable and your network supports replication between sitesCross-site latency raises commit time if the standby is synchronous, so many teams keep it asynchronous. Requires WAN bandwidth planning, certificate and firewall management across sites, and periodic failover drills that include the remote site.
Self-managed failover toolingYour team has the skills and time to build, test and maintain its own detection and promotion logicYour team owns fencing, split-brain prevention, promotion scripts and their testing after every change. Ongoing effort recurs with each PostgreSQL major version and OS update.
Managed failover managerYou want a maintained tool with established failover behavior and you accept its configuration model and dependenciesYou still own its configuration, upgrades, monitoring of the manager itself and failover tests. Ask any partner which tool they support, which versions they test, and what the license terms are.
Reads served from standbysRead-heavy workloads can tolerate replication lag, and your application can tell which queries need current dataApplication teams must handle stale reads and route queries deliberately. Connection routing and lag thresholds become part of the operating runbook.
Routing change after promotionClients must reach the new primary without manual edits after failoverSomeone must own the mechanism that moves traffic, such as a virtual IP, DNS record, proxy or pooler configuration. Define that owner and test the change during every failover drill.

How to build a PostgreSQL HA cluster step by step

This sequence takes a PostgreSQL primary, one or more standbys, a failover manager and a client routing layer from a design to a tested, documented cluster. Each step closes with a check, so the team knows the cluster is ready to hand over only after failover and rebuild have been proven.

  1. Confirm the major version and support end date

    The platform owner selects the PostgreSQL major version and checks its end-of-support date against the versioning policy before any server is built. Confirm the dates on the policy page at the time of build, because the list of supported versions changes as releases age out. Record the version, its end date and the planned upgrade window in the design record. Done when the platform owner has approved the version and the expected end-of-life date is written into the upgrade plan.

  2. Prepare the primary for replication

    The DBA creates a dedicated replication role with a SCRAM password, adds pg_hba.conf entries that allow replication connections only from the standby addresses, and sets WAL parameters such as wal_level, max_wal_senders and the replication slot limit. Enable TLS for replication traffic where the network requires it. Check: the primary restarts cleanly, a replication connection from a standby address succeeds, and the same role is refused from an address that is not listed.

  3. Build the first standby and confirm streaming

    The DBA creates the first standby with pg_basebackup, using the option that writes the standby configuration, and starts it in standby mode. On the primary, pg_stat_replication should show the standby in the streaming state with a small, stable replay lag under a test write load. On the standby, the WAL receiver view should show an active connection to the primary. Done when the state is streaming and the lag stays steady during the test.

  4. Choose and configure synchronous standbys

    The team decides, per workload, whether a commit must wait for a standby before it returns. Synchronous replication protects committed transactions from loss on failover, but a stalled synchronous standby can stall commits unless the configuration accounts for it. Asynchronous replication avoids that stall and accepts a window of possible loss. Configure synchronous_standby_names and synchronous_commit only if the decision requires it. Check: a test commit returns only after the standby acknowledges, and sync_state shows sync. If the team chooses asynchronous, the accepted loss window goes in the runbook.

  5. Install the failover manager with fencing and quorum

    Install the failover manager the design selected, such as Patroni, repmgr or pg_auto_failover, and follow its witness or consensus requirements for quorum. Configure fencing so a node that loses its role cannot keep accepting writes, and confirm the vendor or project documentation for each option. Two-node designs need an external witness or consensus store to avoid split brain. Check: with the primary isolated, the manager elects one new primary, the old primary is fenced, and no two nodes accept writes at the same time.

  6. Configure client routing and run a planned switchover

    Point applications at a stable endpoint such as a virtual IP, a DNS name or a proxy that always routes to the current primary. If PgBouncer or another pooler sits in front, configure it to follow the same endpoint, as covered in the connection pooling topic. Run a planned switchover during a quiet window and watch client reconnect behavior. Check: writes land on the new primary, the former primary becomes a streaming standby, and applications reconnect without manual changes.

  7. Test an unplanned failover and rebuild the former primary

    Simulate a primary crash by stopping the database process or isolating the host, while a test workload runs. Confirm the failover manager promotes one standby, fencing blocks the old primary, and the routing layer moves traffic. Record the commits that were lost, if any, against the replication mode chosen earlier. Rebuild the former primary as a standby using a fresh base backup or pg_rewind. Check: the rebuilt node reaches the streaming state and the cluster reports one leader and the expected number of followers.

  8. Document the runbook and confirm backups are in place

    Write the runbook covering topology, endpoints, switchover and failover procedures, fencing steps, alert thresholds, on-call contacts and the rebuild procedure, and have someone other than the author follow it on a test cluster. Confirm base backups, WAL archiving and point-in-time recovery follow the backup design, as set out in the PostgreSQL backup and point-in-time recovery topic. Declare the cluster ready only after a restore test to a separate host succeeds.

What drives the effort of a PostgreSQL HA project

This table lists the drivers that change how much work a PostgreSQL high availability project takes, how each one changes it, and how to keep it manageable. Effort is set by the written scope, and no price list applies. Tell us about your environments, and we will confirm which drivers apply to yours.

DriverHow it changes the workHow to keep it down
Number of databases and clustersEach cluster needs its own replication, failover, monitoring and test cycle, so effort scales with cluster count.Standardize one cluster template and reuse the same runbooks and automation across clusters.
Data volume and base backup timeLarger data sets lengthen the initial standby copy and any standby rebuild, which raises test and cutover time.Measure a base backup in a test environment early, then plan standby rebuilds around that measured time.
Number of sites and network linksEach site adds replication paths, firewall rules and latency that must be tested during failover.Limit the sites that hold failover-eligible nodes, and document every replication link.
Synchronous versus asynchronous replicationSynchronous standbys make commits wait, so standby health and network latency affect write availability and need more testing.Choose the mode per workload, and confirm the data loss and availability trade-off with system owners before build.
Client applications that must reconnect after failoverEach application's connection string, retry logic and pooler setup must handle a new primary cleanly.Inventory every client and its reconnect behavior, then test each one in a failover rehearsal.
Fencing and split-brain preventionPostgreSQL leaves failure detection to external tools, so the fencing design and tests that prove the old primary stops accepting writes become part of the build.Decide the fencing mechanism during design and reuse one tested pattern across clusters.
Change control and approval for failover testsEach switchover or failover test may need a change record, a maintenance window and sign-off from application owners.Agree a standing test calendar and approval path in the written scope so each rehearsal does not need new negotiation.
Compliance evidence needsAssessors may ask for test records, configuration baselines and restore evidence, which adds documentation and capture work.Agree the evidence list in the written scope. Independent auditors, not DeployOpen, issue any audit opinion.

How the HA design changes by deployment model

A single node has no standby to promote, so availability depends on how quickly you can restore onto replacement hardware or a new virtual machine. The recovery plan rests on a base backup and archived WAL files, which together support point-in-time recovery. Fencing is simpler because only one server holds the data, but you still need a rule that stops a restored copy from accepting writes while the original may still be running.

  • Extra decisions: where backups and WAL archives are stored, and whether they sit outside the failure domain of the server
  • Recovery target: the recovery point and recovery time you can accept, agreed with application owners before go-live
  • Fencing: a runbook step that stops the original instance and confirms it is not serving clients before a restore begins
  • Restore capacity: whether spare hardware or a virtual machine template is ready, and who is authorized to run the restore
  • Client routing: how applications find the restored server, so the cutover does not depend on someone editing configuration by hand

Verify by restoring to a separate host on a schedule, timing each run, and confirming the restored data matches what the application expects. Confirm the expected recovery time with your own team, since it depends on backup size and network throughput in your environment.

How to test PostgreSQL failover and switchover before production

Test switchover and failover as separate exercises, because they promise different things. A switchover is planned: the current primary is deliberately demoted, and once every standby has replayed the primary's final WAL position, no committed transaction should be lost. A failover is unplanned: the primary has crashed or become unreachable, a standby is promoted, and an asynchronous standby may be behind, so commits the primary acknowledged but had not yet shipped can disappear. Before any test runs, write acceptance criteria for each one and get sign-off from the database, platform and application owners. Include the tolerated write pause, the expected data loss for each replication mode, the required state of the old primary, and the evidence that proves each point. Agreeing these in advance keeps the team from calling a result acceptable after seeing it.

Run the test cases against a staging copy with the same topology as production and a steady write workload. Cover a planned switchover with traffic running, a primary crash (a forced stop with no clean shutdown), a network partition between primary and standby, loss of a synchronous standby during commits, failure of the failover manager itself, and client reconnection behavior. For a planned switchover, expect no lost commits and a short write pause that you have measured. For a crash with an asynchronous standby, expect possible loss limited to the replication lag at the moment of failure, and record that lag rather than assuming it. For a partition, the outcome depends on whether the failover manager can reach a quorum, and the cluster must never promote two primaries. For loss of a synchronous standby, the outcome depends on synchronous_standby_names and your commit settings, so the criteria must state which behavior you expect. For a failover manager failure, confirm what your design does: whether the current primary keeps serving and whether automatic promotion stays blocked.

Keep evidence for every run so results can be compared across runs and handed to auditors or the operations team. Record timestamps from each node, with clocks synchronized so events line up across hosts. Capture replication position before and after each event: the primary's current WAL location, each standby's replay location, and the replication status view on the primary. Note the timeline change after promotion, the failover manager's log entries, and the moment the new primary accepted its first write. On the application side, count errors by class (connection refused, read-only transaction, timeout, unique violation after retry) and record how long each client took to reconnect. Store the raw logs with the run, not only a summary, so a reviewer can check the sequence of events later.

Verify that the cluster fails safely, which matters more than the speed of failover. After any promotion, confirm that the old primary cannot accept writes: attempt a write through the application path and through a direct connection, and check that the old node reports it is in recovery or is otherwise unreachable for writes. Verify the fencing mechanism you designed, such as stopping the instance, removing its virtual address, or a fencing agent, and confirm it works during a partition, not only during a clean stop. Check that the old primary cannot rejoin as a writable node without a documented rebuild or rewind step. Finally, confirm that connection poolers and application connection strings route writes only to the new primary after the switch. Any run in which two nodes accept writes at once is a failed test, regardless of the other results.

Securing replication, failover and secrets in a PostgreSQL HA cluster

Replication, failover and secrets form one trust boundary. A replica that connects from the wrong host, a shared replication password or an unrestricted failover command each widens who can read or change the data. The controls below should be defined before the cluster goes live and verified in your own environment.

Replication role privileges

Create a dedicated login role for streaming replication with only the REPLICATION attribute. It should not be a superuser and should not own application schemas or hold data access it does not need. Keep the failover manager on its own role so an audit can tell which process made a change. Review the role list after every cluster change, and confirm with your platform team which privileges the failover manager needs to promote a standby.

Host rules for replication connections

The client authentication file decides which addresses may open a replication connection and which method they must use. Limit replication entries to the specific standby addresses and the failover manager host, avoiding broad subnet ranges. Confirm how your PostgreSQL version handles each authentication method you choose, and check that rule changes reload correctly. Full coverage of these rules sits in the PostgreSQL security hardening topic.

Encrypted connections between nodes

Replication carries WAL data, which includes the contents of changed rows, so the link between the primary and each standby should be encrypted when it crosses networks you do not fully control. Decide where the certificates come from, how they are rotated and whether standbys verify the primary's certificate. Test the setting on a standby before relying on it, and confirm that client connections follow the same rule after a promotion.

Replication and failover secrets

The replication password and the failover manager's database and API credentials belong in the team's secret store, with configuration files holding only references. Confirm who can read each secret, how standbys and the failover manager retrieve it at startup, and how a rotation reaches every node without an unplanned restart window. Record the rotation procedure in the runbook so the on-call team can run it under pressure.

Access control for switchover and failover

Switchover and failover change which node accepts writes, so the ability to trigger them should belong to a small, named group separate from routine database access. Require an approval step or change record for planned switchovers, and log every invocation with the operator's identity. Check that the failover manager's own permissions match this policy, because a tool with broad rights can act outside the approved process.

Operating a PostgreSQL HA cluster after go-live

A PostgreSQL high availability design is only as good as the routine that keeps it working after go-live. The first thing to settle is who watches what, because most failovers that go badly do so because a warning was visible but nobody owned it. Monitor replication state and lag on every standby, standby connectivity from the primary's point of view, the health of the external failover manager, and the availability of any synchronous standby. If a synchronous standby drops out, commits can stall or fall back to asynchronous behavior depending on how the setting is configured, so confirm with your own configuration what happens in that case and alert on it directly. Name an owner and an alert threshold for each of these items before the cluster takes production traffic.

The runbook needs the same discipline. Record the current topology, the failover manager's configuration, the names and roles of every node, the procedure for a planned switchover and for an unplanned failover, and the steps to rejoin a former primary as a standby. Review it after every change to the cluster, including changes to hardware, network paths, certificates, or the failover manager itself. Failover tests should recur on the same trigger. Each change that touches the topology or the failover path should be followed by a test that proves the new arrangement still promotes a standby and that clients reconnect as expected. A test that was passed a year ago describes a cluster that no longer exists.

Minor releases are the routine maintenance task. PostgreSQL minor releases do not change the internal storage format, so applying one means replacing the executables and restarting. In an HA cluster, apply the update to standbys first, then perform a planned switchover before restarting the old primary, so the restart happens on a node that is no longer serving writes. Set the order in writing, including which node goes first, who approves the switchover window, and how client connections are drained. Minor releases arrive at least once every three months under the PostgreSQL versioning policy, so this procedure will run often and should be rehearsed in a non-production environment.

Major upgrades are a separate project. They change the on-disk format and affect the HA topology, because the standbys, the failover manager's configuration and the backup chain all have to follow the new version. Plan the upgrade with its own schedule and rollback point. The two main options are pg_upgrade, which upgrades the data directory in place with a known downtime window, and logical replication, which can move data to a new major version with much less downtime because it works between different major versions. Your choice depends on data size, acceptable downtime and how much change the application can absorb. The upgrades topic covers how these options are weighed and scheduled.

Backups must be taken either from a standby or from the primary, using the approach your team has chosen, such as base backups with WAL archiving or incremental backups reconstructed at restore time. Taking backups from a standby reduces load on the primary, but the team must confirm that the backup captures what it needs and that it still works after a failover changes which node is the source. A backup job that reports success is not evidence that it can be restored. A restore test, carried out on a separate system and checked against expected data and recovery time, is the only proof that a backup works. Agree who runs the restore test, how often, and where the results are recorded. For every item in this section, including monitoring, runbook upkeep, failover tests, minor and major upgrades, and backup and restore tests, ask the team to name the owner in writing.

Questions teams ask before building PostgreSQL high availability

How much effort does PostgreSQL high availability take to build?

Effort depends on the scope you agree, and the main drivers are the number of clusters and nodes, the replication mode, the failover tooling, the state of your existing infrastructure, and how much testing you need to show that failover and switchover behave as designed. The effort drivers table on this page shows how each factor moves the work up or down. The written scope turns those factors into named deliverables, so you can see what is included and excluded before work starts. When you compare offers, ask for effort split by workstream: architecture and design, build, failover and switchover testing, monitoring and alerting, runbooks, and handover to your operations team. Ask how a change to scope during the engagement would be priced and approved. Most engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.

Can our own team build PostgreSQL high availability internally?

Yes, if your team has database administration, network and failover operations skills, and time to test. The build itself is usually the smaller part. Testing is where teams most often underestimate the work. You need to rehearse planned switchover, unplanned loss of the primary, client reconnection, fencing of the old primary, and rejoining a failed node to the cluster. You also need to confirm that backups and archiving still run correctly after a promotion, because the new primary may change where that work happens. Internal teams tend to succeed when one or two engineers own the design, the wider operations group understands the runbooks, and test windows are protected on the calendar. If those conditions are missing, a partner can cover design, build and the test cycle while your team takes over operations. Decide early which parts your team will own after handover.

How long does a PostgreSQL high availability project take?

The schedule depends on the scope and the environment, so it should be confirmed from the written scope rather than estimated from a general description. The main factors are the number of clusters, whether infrastructure and automation already exist, how quickly access and approvals are granted, how change windows for failover tests can be scheduled, and whether monitoring and backups are already in place. Delays usually come from waiting on people and approvals more than from the database work itself. Ask the partner for a written schedule with milestones, the client dependencies behind each milestone, and the test windows it assumes. Check whether the schedule includes a rehearsal period for failover tests and time to correct issues found in the first rehearsal. Confirm the schedule in writing before you commit a date to your own stakeholders, and ask what would move it.

What does our team need to provide for a PostgreSQL high availability engagement?

Plan for environment access, change windows, named owners and one key architecture decision. Access means accounts and network paths to the target nodes, the backup store, monitoring, and the DNS or load balancer that clients use, with enough privilege to install and test. Change windows are needed for planned switchover and failover tests, which can interrupt client connections even when the design is sound. Name an owner for the database, the network, security and each application that connects, with authority to approve changes. The main architecture decision is the replication mode: whether standbys are synchronous, asynchronous or a mix, and how many standbys must confirm a commit. Your team also needs to agree the acceptable data loss and downtime for each service, because those answers set the design. Provide representative test data or a realistic workload so that failover results mean something.

Is synchronous replication always better for PostgreSQL high availability?

No. Synchronous replication trades commit availability for durability. With synchronous standbys, a commit waits until a standby confirms it, so a failover is less likely to lose committed transactions. The cost is that if the required standbys become unavailable or slow, commits can stall, and the primary may stop accepting writes until a standby recovers. Asynchronous replication keeps commits fast and independent of standby health, but a failover can lose the most recent commits that had not reached a standby. Many designs use one synchronous standby with others asynchronous, so a node can be promoted without waiting on every replica. The right choice depends on how much data loss each service can accept, how long writes can wait, and how many standbys your network and hardware can keep healthy. Record the decision and its reasoning, because it shapes monitoring, failover behavior and client expectations.

Does PostgreSQL fail over automatically without extra software?

No. PostgreSQL does not detect a failed primary and promote a standby on its own. It provides streaming replication, hot standby and promotion, but another component must decide that a failure has happened, promote the right standby, and stop the old primary from accepting writes. That external failover manager also has to handle fencing, so two nodes never accept writes at the same time, which is the split-brain risk. Clients need a way to find the new primary, usually through a connection endpoint or proxy that follows the current leader. Choose the tool based on your platform, your operations team's skills and the support model you need. Confirm its features, licensing and support terms with its maintainers or vendor. Then test automatic and manual failover in an environment that matches production.

What should we ask a partner for in a PostgreSQL high availability quote?

A useful quote lists what is included, what you must provide and how changes are handled. Ask for a written scope with numbered deliverables, such as an architecture document, the build of each node, replication and failover configuration, monitoring and alerts, backup integration, a test plan covering each failover and switchover scenario, runbooks, and handover sessions. Ask which items are one-time and which recur, and whether ongoing support is quoted as a separate retainer. Request explicit exclusions, client dependencies with named owners and dates, assumptions about the environment and versions, and acceptance criteria for each test. Ask how a scope change is requested, priced and approved, and how a failed test is handled. DeployOpen plans and implements inside your own infrastructure, and most engagements are fixed-scope with terms agreed in writing before work starts. Compare offers on the written scope and its exclusions.

How DeployOpen scopes, builds and hands over PostgreSQL HA

DeployOpen plans, implements, hardens, backs up, documents and supports self-hosted PostgreSQL high availability inside your own cloud accounts, data centers or air-gapped networks. Each engagement starts from a written, fixed scope that names the replication mode, failover tooling and failover tests before any build work begins.

How we scope

  • Confirm the PostgreSQL major version in use and its end-of-support date before choosing the architecture.
  • Agree whether standbys replicate synchronously or asynchronously, and how much write loss the business accepts.
  • Name the failover manager, the switchover procedure, and the client connection path that follows a role change.

How we build

  • Build a primary with hot standbys using streaming replication, configured for the agreed commit mode.
  • Select and configure an external failover manager, because PostgreSQL does not detect a primary failure on its own.
  • Pair replication with WAL archiving and base backups, since a standby copies errors and cannot replace point-in-time recovery.

How we hand over

  • Test automatic failover and planned switchover in your environment, and record the observed behavior of clients and the application.
  • Deliver runbooks for switchover, failover, rebuilding a standby and checking replication lag.
  • Document configuration and keep test records that internal reviewers or external auditors can examine.

How we support

  • Ongoing support, upgrades and continuous testing are available as a retainer after handover.
  • Plan minor releases on the quarterly cadence and schedule major upgrades before your version reaches end of support.
  • Rerun failover tests after platform changes, such as a minor release, a network change or a failover manager update.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.