What a PostgreSQL health check finds before an outage does
A PostgreSQL health check is a structured review of a running cluster that ends in a findings report with fix priorities. If you inherited a self-hosted cluster, upgraded one recently, or have never had it reviewed, the question is whether it is safe to keep running as it is. The review covers the version and its support status, configuration, replication and backups, vacuum and transaction ID wraparound risk, table and index bloat, security settings such as authentication methods and password hashing, and whether monitoring would warn you before any of these become incidents. The reviewer reads evidence from the server itself: current settings, catalog views, replication status, backup catalogs and restore history. It does not replace your monitoring, but it checks whether the monitoring is watching the right things.
Teams usually commission a review at one of four moments: before a major version upgrade, after an incident such as a read-only wraparound event or a full disk, before an audit that asks for evidence of backups and access control, or when a system has been handed over and nobody on the current team designed it. The support calendar makes the first case concrete. The PostgreSQL versioning policy lists 14 as supported until November 12, 2026, so a cluster on 14 or older needs a plan that a review can shape. Ask for the version check to be tied to the exact minor release and to the upgrade method you intend to use.
The PostgreSQL License allows the software to be run and reviewed without license cost, so the money in a health check goes to people and evidence: the reviewer's time, access to hosts and logs, and the work to verify a restore. Ask the provider to state which evidence they need from you before work starts, such as read-only database access, configuration files, and the last restore test record. Also confirm who will run the commands on production and during which window. A written scope with those answers is what turns a review into a list of fixes you can schedule.
How evidence becomes a findings report
The review starts with read-only access to the database and host, then collects evidence from several sources: catalog queries, configuration files, replication and backup status, monitoring data, and version and support status. Each evidence set is reviewed against its own area, such as vacuum and wraparound risk, backups, or security settings. The reviewer then records each issue as a finding with a severity, and only after that are fixes ranked by priority and confirmed through a retest. The diagram shows the order of these hand-offs, so a reader can see where evidence is checked before any recommendation is made.
Evidence moves from collection through area review into findings, ranked fixes and a retest.
Which review areas to weight for each situation
This table lists the seven review areas in a PostgreSQL health check, the evidence each one needs, and the situations that justify going deeper on it. Use it to decide where a reviewer should spend extra time before the full review starts. The main takeaway is that the version and support check is always quick, while backup, replication and vacuum areas deserve more depth when recovery or uptime targets are tight.
| Review area | What the reviewer checks and the evidence needed | When this area deserves extra depth |
|---|---|---|
| Version and support status | Checks the running major version against the support dates in the versioning policy. Needs SELECT version(); output and the minor release level. | The cluster runs a major version nearing end of support, or a major upgrade is already planned. |
| Configuration | Checks memory, connection, WAL and logging settings against workload. Needs postgresql.conf, ALTER SYSTEM overrides and pg_settings output. | Teams report slowdowns, memory kills or connection errors, or settings were changed by hand without records. |
| Replication and backups | Checks standby lag, replication slots, archiving status and whether point-in-time recovery has been tested. Needs pg_stat_replication, archive status and the backup catalog or tool output. | Recovery point or recovery time targets are strict, or no restore has been tested in the environment. |
| Vacuum and wraparound risk | Checks transaction age per database and table, autovacuum activity and long transactions that block cleanup. Needs pg_database and pg_stat_user_tables age data and autovacuum settings. | Transaction age is high, autovacuum has fallen behind, or large tables receive heavy update or delete traffic. |
| Bloat | Checks dead tuple counts and estimated table and index bloat against the storage footprint. Needs pg_stat_user_tables figures and an agreed bloat estimate method. | Disk use grows faster than data volume, or query plans degrade on tables with heavy churn. |
| Security settings | Checks authentication methods in pg_hba.conf, password encryption, TLS settings, role privileges and superuser use. Needs the HBA file, pg_roles output and TLS configuration. | The database holds regulated data, is reachable from many networks, or still allows MD5 password authentication. |
| Monitoring and alerting | Checks that metrics, logs and alerts exist for lag, age, connections, disk and locks, and that someone receives them. Needs alert rules, dashboard exports and log settings. | Incidents were found by users rather than alerts, or no owner is named for database alerts. |
How the scope changes before an upgrade, after an incident or for an audit
Before a major upgrade, the review starts with version status. PostgreSQL 14 is supported until November 12, 2026, and 13 and earlier are no longer supported, according to the PostgreSQL versioning policy. The reviewer checks extensions, custom types, planner settings and client driver compatibility against the target major version, then chooses between dump and restore, pg_upgrade and logical replication based on the downtime the business accepts.
- Version and target fit: confirm the current minor release, the target major version and the support end date for each cluster in scope.
- Extension and driver compatibility: list every extension, procedural language and client library that must work on the target.
- Rollback path: confirm a tested restore of a recent backup and the exact steps to return traffic to the old cluster.
- Change history: obtain recent DDL history, previous upgrade runbooks and any known failed attempts.
- Access windows: agree a staging copy of production data and a test window long enough to run the upgrade and application tests.
The output is an upgrade plan with go or no-go criteria, a list of blocking items and a rehearsal schedule. Ask the client to confirm which upgrade method has been approved and who signs off the cutover.
When a team takes over a cluster from another team, the review assumes little is documented. It starts with what exists: versions, replication topology, backup jobs and any manual changes made to configuration files outside version control. The reviewer compares the running settings with the files on disk, because the two often differ after past emergency changes.
- Configuration drift: compare live values from
pg_settingswith the files under version control and note every difference. - Backup proof: request the backup schedule, retention rules and the last restore test record, not only the backup job status.
- Replication and slots: map primaries, standbys and replication slots, including slots that no current consumer uses.
- Ownership and access: list superuser roles, application roles and any shared accounts that need an owner.
- Operational history: collect monitoring alerts, incident tickets and maintenance logs from the previous team.
The output is a baseline inventory with a ranked list of unknowns. Ask the outgoing team for read access to configuration, runbooks and the backup catalog, and for a named contact who can answer questions during the first review.
After an incident, the review narrows to the failure and to the systems that could repeat it. The first question is whether the database is stable now. Vacuum and wraparound risk, disk and WAL growth, connection exhaustion and memory limits are checked first, because they are the usual causes of outages. The reviewer works from logs and metrics captured during the incident, and avoids changes to production unless the client approves them in writing.
- Current stability: check transaction age, free disk, active sessions and replication lag at the time of review.
- Incident evidence: collect PostgreSQL logs, OS logs, monitoring exports and the timeline the responders wrote.
- Restore record: if backups were used, obtain the restore log, the target point in time and the checks run afterward.
- Change log: list every configuration change, deploy and failover made during the incident.
- Access window: agree which read-only queries may run on production and at which times.
The output is a root cause hypothesis marked by confidence, immediate containment steps and fixes ranked by priority. Ask the client to confirm whether any emergency change is still in place and needs formal review.
For an assessment, the review focuses on evidence that an independent auditor or assessor can check. Security settings, access control, audit logging, encryption, backup testing and change management are placed first. DeployOpen prepares systems, controls and evidence for compliance assessments, but it does not issue audit reports, attestations or certifications. Independent auditors and certification bodies make those decisions.
- Access control evidence: export role membership,
pg_hba.confrules and the approval record for privileged accounts. - Logging and monitoring: show which events are logged, where logs go and how alerts are routed and reviewed.
- Backup and restore records: provide dated restore test results, not only backup job success messages.
- Change history: supply the change tickets, approvals and deployment records for the period under review.
- Version support: show the current support status of each major version in use and the upgrade plan for any version nearing end of support.
The output is an evidence pack mapped to the assessor's requirements, with gaps listed and fixes scheduled. Ask the assessor early which evidence format and sampling period they expect.
What each of the six review areas checks
A PostgreSQL health check reviews six areas that fail in different ways but share one root: a database that works today can stop accepting writes, lose data or fall over under load. Each card below names the evidence the reviewer reads and one finding that appears often enough to check first.
Version and support status
The reviewer compares the running major version with the supported list and records each end-of-life date. PostgreSQL 14 support ends November 12, 2026, and versions 13 and earlier no longer receive fixes, so a cluster on those releases needs an upgrade plan rather than another patch cycle. The reviewer also checks whether the minor release is current, because minor releases carry security and data-safety fixes and can be applied by replacing executables and restarting. Common finding: a cluster running an unsupported major version with no owner or upgrade date.
Versioning policyConfiguration against workload
The reviewer reads the effective settings for memory, connections, logging and archiving and compares them with the server's RAM, storage type and actual traffic. Values copied from older tuning guides often ignore how many sessions run at once and how much memory each one can claim for sorts and hashes. Logging settings are checked for whether slow queries and lock waits are recorded at all. Common finding: defaults left in place on a server whose memory and connection counts have grown since installation.
Replication and backups
The reviewer confirms each standby is streaming, whether it runs in synchronous or asynchronous mode and whether that mode matches the data-loss tolerance the business stated. WAL archiving is checked for recent successful runs, and base backups are checked for age and completion. A backup that has never been restored is treated as unproven, so the reviewer asks for the date of the last restore test and what it measured. Common finding: WAL archiving failing silently while backup jobs still report success.
Continuous archiving docsVacuum and wraparound risk
The reviewer reads the age of the oldest transaction ID in each database and table and checks whether autovacuum keeps up with write volume. Long-running transactions and idle sessions holding old snapshots are noted because they stop vacuum from cleaning dead rows and freezing old IDs. The review confirms that autovacuum is enabled and that its logs show completed runs rather than repeated cancellations. Common finding: one large table whose freeze age keeps climbing because autovacuum never finishes on it.
Bloat and table growth
The reviewer compares table and index sizes with the live data they hold and looks for growth that does not track row counts. Heavy update or delete patterns, and indexes that were never rebuilt after large deletes, are the usual sources of extra space. Results are ranked by how much space they waste and by how often the affected objects are written, since a bloated table that is rarely touched is a lower priority. Common finding: indexes several times larger than the data they cover after years of updates.
Security settings and monitoring
The reviewer checks the authentication methods in the host-based access file, whether TLS is required for remote connections, and whether password storage uses SCRAM rather than the deprecated MD5 method. Role privileges are reviewed for superuser and broad write grants, and the alerts configured for disk, replication lag, connection counts and vacuum age are compared with the incidents that have actually occurred. Common finding: MD5 password hashes still in use and no alert on replication lag or disk growth.
Authentication methods docsHow findings are ranked into fix priorities
A finding is ranked by the outage or data-loss risk it carries, not by how many findings a review produces. Each item is scored on three questions: how bad the failure would be, how soon the risk could be reached, and how much work the fix needs. A short list of high-impact, near-term items usually matters more than a long list of hygiene issues, and a health check report should say so explicitly so that the first items in the queue are the ones that can cause loss or downtime this quarter.
Illustrative example: a backup job that reports success but has never been restored ranks above a finding that log_line_prefix omits a field the security team would like to see. The backup finding may take a day to test, while the logging change takes minutes, but the backup risk can end in unrecoverable data and the logging gap only slows an investigation. Two rules shape the ordering. An unsupported major version is treated as a planning item with a fixed end date, not as an emergency, so its position depends on how close the end of support is and how much upgrade work the team must absorb. A backup that has never been restored is treated as unproven until a restore test passes, and it ranks high regardless of how well the backup tool reports.
Confirm the end-of-support date for your major version against the PostgreSQL versioning policy before you set its priority, and ask the reviewer to record the evidence behind each rank: the query output, the restore log or the setting value. Priorities should be agreed with the owners of each system, since the same finding can rank differently for a database that feeds payments and one that serves an internal report.
How a PostgreSQL health check runs from kickoff to retest
The sequence moves from a written scope and read-only access to a findings report, agreed fix priorities and a retest, so the owner knows what is wrong, how serious it is and what has been verified as fixed.
Agree written scope and read-only access
Before any evidence is collected, the client and the reviewer agree in writing which clusters, databases, hosts and monitoring sources are in scope, which PostgreSQL versions apply, and who approves access. The reviewer works with a read-only role that can read system views, catalog data and monitoring dashboards but cannot change settings, data or roles. Any change to production is made by the client's team or in an agreed window, never by the reviewer during the review. This step is done when the scope document and the access record are signed off by the system owner.
Collect read-only evidence from server and monitoring
The reviewer gathers the facts the review depends on: the server version and minor release level,
postgresql.confandpg_hba.confsettings, replication status and slot state, backup and archive logs, transaction age figures, table and index size statistics, connection counts, and the alerts and dashboards already in place. Where the client cannot provide a source, such as backup job history or monitoring retention, the gap is recorded rather than guessed. This step is done when each evidence item is saved with its source, timestamp and the query or view used to obtain it.Review each area against the agreed scope
The reviewer checks each area in the agreed scope against the evidence: version and support status, configuration, replication and backups, vacuum and transaction ID wraparound risk, bloat, security settings and monitoring. Each area is marked as reviewed, not applicable or blocked by missing access. Results are compared with the documented behavior for the installed version rather than with generic thresholds. This step is done when every in-scope area has a recorded result, including the areas that look healthy.
Validate high-impact findings safely
Findings that could cause an outage, data loss or a security exposure are confirmed before they are reported as serious. Validation uses read-only checks where possible, such as confirming a restore point exists by reading backup metadata, or reviewing a recent test restore record. Where a test needs a write or a load, the reviewer proposes it and the client approves it on a non-production copy or in an agreed window. This step is done when each high-impact finding has either confirmed evidence or a clear note of what remains unverified.
Write the findings report with severity and evidence
The reviewer writes a report that lists each finding with a severity rating, a plain description of the risk, the evidence that supports it, the affected component, and a recommended fix. Severity reflects the likely impact on availability, recovery, data integrity and security, and the report states the basis for each rating. Items that could not be checked are listed separately so the owner knows what is still open. This step is done when the draft report has been checked against the evidence log and sent to the client for factual review.
Agree fix priorities with the owner
The reviewer and the system owner meet to agree which findings are fixed first, who owns each fix, and whether the fix is made by the client's team or by a partner under a separate scope. The discussion covers dependencies, such as a minor upgrade that must come before a configuration change, and any fix that needs a change window. Disagreements about severity are recorded with the reason on each side. This step is done when the owner signs off a prioritized list with named owners.
Retest the fixes that were applied
After the client's team applies the agreed fixes, the reviewer repeats the relevant checks and compares the new evidence with the original finding. A finding is closed only when the retest shows the change in the system, not when a ticket is marked done. Fixes that were not applied, or that changed the risk in a different way, stay open with a note. This step is done when the retest record lists each finding as closed, open or changed, with the evidence for each status.
Security and access rules for the review itself
A health check gives the reviewer broad visibility into a production database, so the review needs its own rules. The cards below cover access, data handling, query impact, authentication checks and how findings travel, and they apply whether the review runs on-site or through a remote session inside your environment.
Read-only roles and credential handling
The review runs under a dedicated read-only role, created by your team, that can read catalog views and statistics without rights to change data, schemas or settings. Credentials stay in your secrets store or a session you control, not in the report, a shared notebook or a chat thread. Confirm the role's grants in writing before the first session, and confirm when the account is removed.
Config files and logs with personal data
Log files and some configuration values can contain client addresses, usernames, query text with customer identifiers or connection strings with embedded passwords. The reviewer should read logs only from locations you approve, redact or exclude sensitive lines before anything leaves your environment, and keep working copies inside the agreed storage. Agree this handling before the review starts, not after the first log is opened.
Queries that avoid production impact
Catalog-wide scans, such as full-table size calculations or bloat estimates across every relation, can take locks or consume I/O on a busy system. The review uses lightweight views and statistics first, sets statement timeouts on its sessions, and schedules heavier checks for a window you approve. Ask for the list of queries in advance so your DBA can review each one against the workload.
Authentication and TLS checks
The review reads pg_hba.conf and the password encryption setting to see whether MD5 password authentication still appears on any rule. PostgreSQL 18 deprecates MD5 in favor of SCRAM, so a finding here is a migration task, not an emergency. It also checks whether TLS is enforced for remote connections and which certificate and authentication methods are configured. Only the settings are read, never password hashes or private keys.
Secure sharing of findings
The findings report can reveal weak points, so it travels only through the channel you choose, such as your document store or an encrypted file share with access limited to named recipients. Evidence excerpts are trimmed to the minimum needed to reproduce a finding. Agree the retention period and the deletion step for working files at the end of the engagement, and confirm both in the written scope.
What a PostgreSQL health check costs and what it needs from your team
What drives the cost and effort of a PostgreSQL health check?
The main drivers are the number of clusters, the size and age of the estate, whether backup evidence exists and can be shown, the number of environments (production, staging, disaster recovery), and whether the review is paired with fixes. Each cluster needs its own configuration, replication, backup and vacuum review, so effort grows with the cluster count. Missing backup records take longer to assess because the reviewer has to reconstruct what ran and whether a restore was ever tested. A review that stops at findings costs less than one that includes implementing the fixes and validating them in a change window. Ask any provider for a written scope that lists clusters, environments, the review areas and whether remediation is included, then compare quotes against that list. DeployOpen does not publish prices; a quote follows from the written scope.
Can our own team run a PostgreSQL health check without a partner?
Yes, a team with working PostgreSQL administration experience can run most of the review, but it needs skills across several areas. The team should be comfortable reading postgresql.conf and pg_hba.conf, querying system views such as pg_stat_activity and pg_stat_replication, checking transaction age against the wraparound threshold, reviewing replication slots and archive status, and planning a restore test. Security review also requires familiarity with password encryption, TLS and role privileges. The main risk for internal teams is not technical depth but independence: people who run the database often miss problems they have normalized. Using the PostgreSQL versioning policy to confirm support status is a simple first step. A partner review adds an outside reviewer and a standard findings format, which many compliance teams ask for.
What must our team provide before a PostgreSQL health check starts?
The reviewer needs access and evidence that reflects the running systems, not only the design documents. Typical inputs are:
- Read access to the cluster through an agreed account, plus host or container details where relevant
postgresql.conf,pg_hba.confand any override files, plus the deployment manifests or automation that generated them- Exports or dashboards from your monitoring system covering a representative period, including transaction age, replication lag and disk use
- Backup records: schedules, base backup and WAL archive logs, retention settings, and the most recent restore test results
- Replication topology, failover tooling and any connection pooler configuration
- A change window for validation if fixes will be applied and checked
Ask the provider to confirm exactly which of these it needs and how credentials will be handled. If restore evidence does not exist, that is itself a finding to record, not a reason to skip the review.
Does a PostgreSQL health check change anything in production?
A read-only health check should not change production data or configuration. The reviewer collects settings, catalog information and statistics, and reads logs and backup records. Some queries against system views are lightweight, but reviews of large estates should still agree on timing and which queries run. Any change, such as a new max_connections value, a vacuum adjustment or a password encryption update, is a separate step. It should be made under your change process, in an agreed window, and validated afterward. Ask the provider to state in writing which activities touch live systems, which run on copies, and who approves any change before it is made.
What does a PostgreSQL health check findings report contain?
A useful report separates evidence from opinion and ranks fixes. It should include the scope and the environments reviewed, the PostgreSQL version and its support status under the versioning policy, and a per-cluster section covering configuration, replication and failover design, backup and restore evidence, vacuum and transaction age risk, bloat indicators, authentication and encryption settings, and monitoring coverage. Each finding should state what was observed, where the evidence came from, the risk if it is left alone, and a recommended fix with an owner and priority. Ask for the report template before the engagement starts, and confirm whether it will list items that were out of scope or could not be verified. DeployOpen prepares systems, controls and evidence for compliance assessments, but it does not issue audit reports or certifications; independent auditors do that work.
How does retesting work after fixes are applied?
Retesting checks that each finding was closed and that the fix did not create a new problem. The usual approach is to re-run the same checks against the same evidence sources, record the before and after state for each item, and mark findings as closed, partly closed or open with a reason. Some fixes, such as restore testing or failover drills, can only be confirmed by running the procedure again under observation. Confirm in the written scope whether retesting is included, how many rounds it covers, and whether it applies to every cluster or a sample. For ongoing confidence, ask whether a retainer covering periodic reviews and upgrade support is a better fit than a single engagement.
Which PostgreSQL health check findings are most likely to need a fix quickly?
Findings that threaten availability or data recovery usually come first. Examples include transaction age approaching the wraparound limit, a backup chain that has never been restored, replication slots holding back WAL, an unsupported major version, and authentication that still allows MD5 password storage. Performance findings such as bloat or missing indexes are often important but can be scheduled. The ranking should follow your recovery point and recovery time targets, which are your decisions. Ask the reviewer to explain how each priority was assigned so your team can challenge it.
What a health check cannot confirm on its own
A health check reads configuration, logs, catalog views and documentation, but several conditions only show up under real load, during a real restore or in the systems around the database. The cards below name those limits so the findings report is read as a starting point, with each gap closed by a specific test or confirmation in your environment.
Restore within recovery targets
A health check can confirm that backups are configured, that WAL archiving is running and that a base backup exists. It cannot confirm that a restore completes within your recovery time objective or that the recovered data is consistent and complete up to the recovery point you need. Ask for a timed point-in-time recovery into an isolated environment, measure the elapsed time against your target, and run application checks on the restored database. Point-in-time recovery depends on a base backup plus archived WAL, so a gap in the archive can stop the restore at an earlier point than expected.
Continuous archiving docsFailover without an external tool
PostgreSQL does not detect a failed primary or promote a standby by itself, so a health check sees replication status but not whether failover will happen. The failover tooling, its fencing method, its health check thresholds and its promotion rules must be reviewed as a separate piece. Confirm who or what triggers promotion, how the old primary is prevented from accepting writes, and how clients are redirected. Test the sequence with a planned switchover and an unplanned stop of the primary.
Failover docsHardware, storage and hypervisor behavior
Queries run against the database host, its disks, its network and its hypervisor, and a health check usually sees these only through the database's own counters. Storage latency spikes, disk write-cache settings, memory overcommit on the hypervisor, and CPU steal can all cause timeouts and replication lag that look like database problems. Ask for host-level metrics for disk latency, memory pressure and network errors over a representative period, and confirm that storage honors the flush behavior PostgreSQL relies on for durability.
Running minor release and pooler version
A health check compares the running server version against the support dates for its major version, but the minor release you are on is a point-in-time fact that must be confirmed on the host and the database. Minor releases do not change the storage format, so applying them means replacing executables and restarting. If PgBouncer is in use, confirm its installed version as well: version 1.26.1 was released on October 14, 2026 with security fixes, so a pooler older than that should be reviewed against the project's release notes.
PgBouncer siteReal application query patterns
A health check runs against catalog views and sampled statistics, which describe the workload at the time of the check rather than the peaks your application produces. Batch jobs, month-end reports, ORM-generated queries and connection pool bursts often drive lock waits, bloat and vacuum lag that do not appear in a quiet snapshot. Ask the application team for their peak schedule and the top queries by time, and confirm that the slow query and lock monitoring you set up captures those windows before signing off on the tuning recommendations.
How DeployOpen scopes and delivers a PostgreSQL health check
DeployOpen runs a PostgreSQL health check as a fixed-scope engagement inside your own infrastructure, so the review covers the servers, backups and monitoring your team actually operates. Each engagement ends with a written findings report, fix priorities agreed with your team, and optional ongoing support as a retainer.
How we scope
- Agree in writing which PostgreSQL clusters, hosts and environments the review covers before any access is granted.
- List the replication, backup, monitoring and authentication components in scope so nothing is assumed to exist.
- Confirm the read-only access, configuration exports and log samples your team will provide for the review.
How we build
- Check the running major version against the published support dates and record how far each cluster is from end of life.
- Review configuration, vacuum and wraparound margins, replication lag, backup coverage and pg_hba.conf rules against your own targets.
- Test restore procedures from your backups where your team agrees, so recovery claims are verified rather than assumed.
How we hand over
- Deliver a written findings report that states each issue, the evidence behind it and the environment it affects.
- Rank fixes by risk and effort in a priority list your engineers and managers can plan against.
- Walk through the report with your platform, security and database owners and record the decisions taken.
How we support
- Offer fix implementation and follow-up checks as a separate, scoped piece of work agreed in writing.
- Provide ongoing support, upgrades and continuous testing as a retainer when your team wants recurring coverage.
- Ask for a quote built from the written scope, since DeployOpen does not publish a price list.

