BARMAN-CLOUD-RESTORE(1)
π BARMAN-CLOUD-RESTORE β bestie edition π
okay so this is barman-cloud-restore, one of the barman-cloud commands, and it's literally the moment where your backup comes home. π β¨
π SYNOPSIS
barman-cloud-restore
[ { -V | --version } ]
[ --help ]
[ { { -v | --verbose } | { -q | --quiet } } ]
[ { -t | --test } ]
[ --cloud-provider { aws-s3 | azure-blob-storage | google-cloud-storage } ]
[ --endpoint-url ENDPOINT_URL ]
[ --addressing-style { auto | virtual | path } ]
[ { -P | --aws-profile } AWS_PROFILE ]
[ --profile AWS_PROFILE ]
[ --read-timeout READ_TIMEOUT ]
[ --sse-customer-key SSE_CUSTOMER_KEY ]
[ { --azure-credential | --credential } { azure-cli | managed-identity | default } ]
[ --snapshot-recovery-instance SNAPSHOT_RECOVERY_INSTANCE ]
[ --snapshot-recovery-zone GCP_ZONE ]
[ --aws-region AWS_REGION ]
[ --gcp-zone GCP_ZONE ]
[ --azure-resource-group AZURE_RESOURCE_GROUP ]
[ --tablespace NAME:LOCATION [ --tablespace NAME:LOCATION ... ] ]
[ --target-lsn LSN ]
[ --target-time TIMESTAMP ]
[ --target-tli TLI ]
SOURCE_URL SERVER_NAME BACKUP_ID RECOVERY_DESTINATION
β¨ DESCRIPTION β¨
Use this script to restore a backup directly from cloud storage that was created with the barman-cloud-backup command. π«Ά And not only that β this script can also prepare for recovery from a snapshot backup by verifying that attached disks were cloned from the correct snapshots, and by downloading the backup label from object storage. two jobs, both iconic. π
π¨ real talk, bestie: this command does not automatically prepare Postgres for recovery. You have to manually manage any PITR options, custom restore_command values, signal files, or required WAL files to make sure Postgres actually starts β whether you do it by hand or with external tools. no autopilot here, the vibes are on you. π
Note:
For GCP, only authentication withGOOGLE_APPLICATION_CREDENTIALSenv is supported. To use an alternative GCP universe (e.g. S3NS/T-Systems), set theGOOGLE_CLOUD_UNIVERSE_DOMAINenvironment variable to the desired universe domain. ππ«
πΈ PARAMETERS πΈ
SERVER_NAMEβ the name of the server that holds the backup you wanna restore. like, whose backup is this? πSOURCE_URLβ the URL of the cloud source, such as a bucket in AWS S3. For example:s3://bucket/path/to/folder. π¦BACKUP_IDβ the ID of the backup to be restored. You can use a shortcut instead of the backup ID. And besides that, you can useautoto have Barman automatically find the most suitable backup for the restore operation. auto is giving β¨let the algorithm decideβ¨.RECOVERY_DESTINATIONβ the path to a directory for recovery. where it all lands. π
π OPTIONS π
-V/--versionβ show version and exit. quick lil flex. π--helpβ show this help message and exit.-v/--verboseβ increase output verbosity (e.g.,-vvis more than-v). more tea, more info. π΅-q/--quietβ decrease output verbosity (e.g.,-qqis less than-q). shhh. π€«-t/--testβ test cloud connectivity and exit. vibe check the connection. π₯--cloud-providerβ the cloud provider to use as a storage backend. Allowed options are:aws-s3.azure-blob-storage.google-cloud-storage.
--snapshot-recovery-instanceβ instance where the disks recovered from the snapshots are attached.--tablespaceβ tablespace relocation rule.--target-lsnβ the recovery target lsn, e.g.,3/64000000.--target-timeβ the recovery target timestamp with or without timezone, in the format%Y-%m-%d %H:%M:%S.--target-tliβ the recovery target timeline.
π EXTRA OPTIONS FOR THE AWS CLOUD PROVIDER π
--endpoint-urlβ override default S3 endpoint URL with the given one.--addressing-styleβ the addressing style to use for S3 requests. This is useful when connecting to S3-compatible services that require a specific addressing style. Allowed options are:auto(default): Uses the addressing style determined by the underlying library.virtual: Uses virtual-hosted style addressing (e.g.,bucket-name.s3.amazonaws.com).path: Uses path-style addressing (e.g.,s3.amazonaws.com/bucket-name).
-P/--aws-profileβ profile name (e.g. INI section in AWS credentials file).--profile(deprecated) β profile name (e.g. INI section in AWS credentials file) β replaced by--aws-profile. she's retired, use the new one bestie. π--read-timeoutβ the time in seconds until a timeout is raised when waiting to read from a connection (defaults to60seconds).--sse-customer-keyβ the customer-provided encryption key (SSE-C) to use for decrypting data in S3. The value must be afile://URI pointing to a file containing a base64-encoded 256-bit (32-byte) key (e.g.file:///etc/barman/sse-c.b64). π
Important: All backups and WAL files for a given server must be encrypted with the same SSE-C key. Mixing SSE-C-encrypted and unencrypted objects, or using different keys across backups, will cause barman commands to fail when S3 rejects requests with a mismatched or missing key. no key-mixing, periodt. π€
--aws-regionβ the name of the AWS region containing the EC2 VM and storage volumes defined by the--snapshot-instanceand--snapshot-diskarguments.
π§ EXTRA OPTIONS FOR THE AZURE CLOUD PROVIDER π§
--azure-credential/--credentialβ optionally specify the type of credential to use when authenticating with Azure. If omitted then Azure Blob Storage credentials will be obtained from the environment and the default Azure authentication flow will be used for authenticating with all other Azure services. If no credentials can be found in the environment then the default Azure authentication flow will also be used for Azure Blob Storage. Allowed options are:azure-cli.managed-identity.default.
--azure-resource-groupβ the name of the Azure resource group to which the compute instance and disks defined by the--snapshot-instanceand--snapshot-diskarguments belong.
π¦ EXTRA OPTIONS FOR GCP CLOUD PROVIDER π¦
--gcp-zoneβ zone of the disks from which snapshots should be taken.--snapshot-recovery-zone(deprecated) β zone containing the instance and disks for the snapshot recovery β replaced by--gcp-zone. another one headed to the retirement home, we love her tho. π«Ά
π AUTHOR
EnterpriseDB
π COPYRIGHT
Β© Copyright EnterpriseDB UK Limited 2011-2026
and that's the whole page bestie!! this was version 3.20 from Sep 29, 2026 β go restore something iconic, ily, mwah πβ¨
π¦ where this page comes from
- epel 10: barman-cli 3.20.1-1.el10_3 Β· GPL-3.0-only
- fedora 43: barman-cli 3.20.1-1.fc43 Β· GPL-3.0-only
- fedora 43: barman-cli 3.20.1-3.fc43 Β· GPL-3.0-only
- fedora 44: barman-cli 3.20.1-1.fc44 Β· GPL-3.0-only
- fedora 44: barman-cli 3.20.1-3.fc44 Β· GPL-3.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms