Analysis updated 2026-05-18
Set up continuous PostgreSQL backup with WAL streaming for point-in-time recovery to any moment in time
Protect a Patroni high-availability PostgreSQL cluster with gap-free WAL streaming across leader switchovers
Deploy pg_hardstorage as a backup agent alongside a CloudNativePG-managed cluster on Kubernetes
Evaluate the full backup, restore, and verify flow using the included Docker Compose stack with MinIO and Grafana
| cybertec-postgresql/pg_hardstorage | mitchellh/go-fs | awuqing/backupx | |
|---|---|---|---|
| Stars | 88 | 92 | 96 |
| Language | Go | Go | Go |
| Last pushed | — | 2018-05-08 | — |
| Maintenance | — | Dormant | — |
| Setup difficulty | moderate | easy | easy |
| Complexity | 4/5 | 2/5 | 3/5 |
| Audience | ops devops | developer | ops devops |
Figures from each repo's GitHub metadata at analysis time.
Requires a PostgreSQL replication user and an accessible storage backend, the built-in Docker demo lets you test the full backup-restore flow without an existing database.
pg_hardstorage is a backup tool for PostgreSQL databases, distributed as a single static binary written in Go. It is designed to provide continuous, byte-precise protection by combining two running processes: one that streams every database change log (called a WAL, or write-ahead log) to a storage repository in real time, and a second that takes periodic full base backups to anchor the stream. Together they enable point-in-time recovery, meaning you can restore the database to any specific moment, not just the last nightly snapshot. The central idea is that WAL streaming is always on. A process holds a replication slot inside PostgreSQL and ships every byte of changes as they are written, without needing access to the database host's operating system or file system. The connection uses PostgreSQL's standard replication protocol over an ordinary network connection. This design means pg_hardstorage can protect PostgreSQL running on bare metal, VMs, Patroni high-availability clusters, and databases managed by Kubernetes operators, as long as the replication protocol is available. Fully-managed cloud databases that disable the replication protocol are not supported. Storage backends include local files, S3, Google Cloud Storage, Azure Blob, SFTP, and SCP. Encryption uses AES-256-GCM, and the tool integrates with four cloud key management services: AWS KMS, GCP KMS, Azure Key Vault, and HashiCorp Vault. Content-aware deduplication reduces repository size without relying on incremental backup chains. Getting started is designed to be fast. A one-liner install script or Homebrew handles installation. Running the demo command in Docker demonstrates the full backup and restore cycle without any existing configuration. An interactive menu mode offers numbered actions (set up, back up, restore, verify) instead of requiring you to remember every command flag. A Docker Compose stack with MinIO, Prometheus, and Grafana is also included for a fuller evaluation environment. The tool supports PostgreSQL versions 15 through 18 and is released under the Apache 2.0 license.
A single Go binary that protects PostgreSQL databases through continuous WAL streaming and scheduled base backups, enabling point-in-time recovery to any moment without OS-level access to the database host.
Mainly Go. The stack also includes Go, PostgreSQL, S3.
Apache 2.0: use freely for any purpose including commercial, keep the copyright and license notices when redistributing.
Setup difficulty is rated moderate, with roughly 30min to a first successful run.
Mainly ops devops.
This repo across BitVibe Labs
Verify against the repo before relying on details.