| 1 |
.\" Man page generated from reStructuredText |
| 2 |
.\" by the Docutils 0.22.4 manpage writer. |
| 3 |
. |
| 4 |
. |
| 5 |
.nr rst2man-indent-level 0 |
| 6 |
. |
| 7 |
.de1 rstReportMargin |
| 8 |
\\$1 \\n[an-margin] |
| 9 |
level \\n[rst2man-indent-level] |
| 10 |
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] |
| 11 |
- |
| 12 |
\\n[rst2man-indent0] |
| 13 |
\\n[rst2man-indent1] |
| 14 |
\\n[rst2man-indent2] |
| 15 |
.. |
| 16 |
.de1 INDENT |
| 17 |
.\" .rstReportMargin pre: |
| 18 |
. RS \\$1 |
| 19 |
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] |
| 20 |
. nr rst2man-indent-level +1 |
| 21 |
.\" .rstReportMargin post: |
| 22 |
.. |
| 23 |
.de UNINDENT |
| 24 |
. RE |
| 25 |
.\" indent \\n[an-margin] |
| 26 |
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] |
| 27 |
.nr rst2man-indent-level -1 |
| 28 |
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] |
| 29 |
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u |
| 30 |
.. |
| 31 |
.TH "BARMAN-CLOUD-BACKUP-DELETE" "1" "Sep 29, 2026" "3.20" "Barman" |
| 32 |
.SH NAME |
| 33 |
barman-cloud-backup-delete \- Barman-cloud Commands |
| 34 |
.sp |
| 35 |
\fBSynopsis\fP |
| 36 |
.INDENT 0.0 |
| 37 |
.INDENT 3.5 |
| 38 |
.sp |
| 39 |
.EX |
| 40 |
barman\-cloud\-backup\-delete |
| 41 |
[ { \-V | \-\-version } ] |
| 42 |
[ \-\-help ] |
| 43 |
[ { { \-v | \-\-verbose } | { \-q | \-\-quiet } } ] |
| 44 |
[ { \-t | \-\-test } ] |
| 45 |
[ \-\-cloud\-provider { aws\-s3 | azure\-blob\-storage | google\-cloud\-storage } ] |
| 46 |
[ \-\-endpoint\-url ENDPOINT_URL ] |
| 47 |
[ \-\-addressing\-style { auto | virtual | path } ] |
| 48 |
[ { \-r | \-\-retention\-policy } RETENTION_POLICY ] |
| 49 |
[ { \-m | \-\-minimum\-redundancy } MINIMUM_REDUNDANCY ] |
| 50 |
[ { \-b | \-\-backup\-id } BACKUP_ID] |
| 51 |
[ \-\-dry\-run ] |
| 52 |
[ \-\-check\-object\-lock ] |
| 53 |
[ { \-P | \-\-aws\-profile } AWS_PROFILE ] |
| 54 |
[ \-\-profile AWS_PROFILE ] |
| 55 |
[ \-\-read\-timeout READ_TIMEOUT ] |
| 56 |
[ \-\-sse\-customer\-key SSE_CUSTOMER_KEY ] |
| 57 |
[ { \-\-azure\-credential | \-\-credential } { azure\-cli | managed\-identity | default } ] |
| 58 |
[\-\-batch\-size DELETE_BATCH_SIZE] |
| 59 |
SOURCE_URL SERVER_NAME |
| 60 |
.EE |
| 61 |
.UNINDENT |
| 62 |
.UNINDENT |
| 63 |
.sp |
| 64 |
\fBDescription\fP |
| 65 |
.sp |
| 66 |
The \fBbarman\-cloud\-backup\-delete\fP script is used to delete one or more backups created |
| 67 |
with the \fBbarman\-cloud\-backup\fP command from cloud storage and to remove the associated |
| 68 |
WAL files. |
| 69 |
.sp |
| 70 |
Backups can be specified for deletion either by their backup ID |
| 71 |
(as obtained from \fBbarman\-cloud\-backup\-list\fP) or by a retention policy. Retention |
| 72 |
policies mirror those used by the Barman server, deleting all backups that are not required to |
| 73 |
meet the specified policy. When a backup is deleted, any unused WAL files associated with |
| 74 |
that backup are also removed. |
| 75 |
.sp |
| 76 |
WALs are considered unused if: |
| 77 |
.INDENT 0.0 |
| 78 |
.IP \(bu 2 |
| 79 |
The WALs predate the begin_wal value of the oldest remaining backup. |
| 80 |
.IP \(bu 2 |
| 81 |
The WALs are not required by any archival backups stored in the cloud. |
| 82 |
.UNINDENT |
| 83 |
.sp |
| 84 |
\fBNote:\fP |
| 85 |
.INDENT 0.0 |
| 86 |
.INDENT 3.5 |
| 87 |
For GCP, only authentication with \fBGOOGLE_APPLICATION_CREDENTIALS\fP env is supported. |
| 88 |
To use an alternative GCP universe (e.g. S3NS/T\-Systems), set the |
| 89 |
\fBGOOGLE_CLOUD_UNIVERSE_DOMAIN\fP environment variable to the desired universe domain. |
| 90 |
.UNINDENT |
| 91 |
.UNINDENT |
| 92 |
.sp |
| 93 |
\fBImportant:\fP |
| 94 |
.INDENT 0.0 |
| 95 |
.INDENT 3.5 |
| 96 |
Each backup deletion involves three separate requests to the cloud provider: one for |
| 97 |
the backup files, one for the \fBbackup.info\fP file, and one for the associated WALs. |
| 98 |
Deleting by retention policy may result in a high volume of delete requests if a |
| 99 |
large number of backups are accumulated in cloud storage. |
| 100 |
.UNINDENT |
| 101 |
.UNINDENT |
| 102 |
.sp |
| 103 |
\fBImportant:\fP |
| 104 |
.INDENT 0.0 |
| 105 |
.INDENT 3.5 |
| 106 |
Starting with AWS boto3 1.36, the behavior of \fBData Integrity Protection checks\fP |
| 107 |
has changed. Some methods used by Barman no longer require the \fBContent\-MD5\fP |
| 108 |
header. |
| 109 |
.sp |
| 110 |
This means that \fBS3\-compatible storage providers that have not updated their |
| 111 |
server\-side code may fail\fP when used with newer boto3 versions. For example, MinIO |
| 112 |
addressed this change shortly after the boto3 1.36 announcement. |
| 113 |
.sp |
| 114 |
If you are using MinIO, you \fBmust upgrade\fP to the latest release (or at least |
| 115 |
\fBRELEASE.2025\-02\-03T21\-03\-04Z\fP or newer) to ensure compatibility and avoid |
| 116 |
failures. |
| 117 |
.UNINDENT |
| 118 |
.UNINDENT |
| 119 |
.sp |
| 120 |
\fBParameters\fP |
| 121 |
.INDENT 0.0 |
| 122 |
.TP |
| 123 |
.B \fBSERVER_NAME\fP |
| 124 |
Name of the server that holds the backup to be deleted. |
| 125 |
.TP |
| 126 |
.B \fBSOURCE_URL\fP |
| 127 |
URL of the cloud source, such as a bucket in AWS S3. For example: |
| 128 |
\fBs3://bucket/path/to/folder\fP\&. |
| 129 |
.TP |
| 130 |
.B \fB\-V\fP / \fB\-\-version\fP |
| 131 |
Show version and exit. |
| 132 |
.TP |
| 133 |
.B \fB\-\-help\fP |
| 134 |
show this help message and exit. |
| 135 |
.TP |
| 136 |
.B \fB\-v\fP / \fB\-\-verbose\fP |
| 137 |
Increase output verbosity (e.g., \fB\-vv\fP is more than \fB\-v\fP). |
| 138 |
.TP |
| 139 |
.B \fB\-q\fP / \fB\-\-quiet\fP |
| 140 |
Decrease output verbosity (e.g., \fB\-qq\fP is less than \fB\-q\fP). |
| 141 |
.TP |
| 142 |
.B \fB\-t\fP / \fB\-\-test\fP |
| 143 |
Test cloud connectivity and exit. |
| 144 |
.TP |
| 145 |
.B \fB\-\-cloud\-provider\fP |
| 146 |
The cloud provider to use as a storage backend. |
| 147 |
.sp |
| 148 |
Allowed options are: |
| 149 |
.INDENT 7.0 |
| 150 |
.IP \(bu 2 |
| 151 |
\fBaws\-s3\fP\&. |
| 152 |
.IP \(bu 2 |
| 153 |
\fBazure\-blob\-storage\fP\&. |
| 154 |
.IP \(bu 2 |
| 155 |
\fBgoogle\-cloud\-storage\fP\&. |
| 156 |
.UNINDENT |
| 157 |
.TP |
| 158 |
.B \fB\-b\fP / \fB\-\-backup\-id\fP |
| 159 |
ID of the backup to be deleted. You can use a shortcut instead of the backup ID. |
| 160 |
.TP |
| 161 |
.B \fB\-m\fP / \fB\-\-minimum\-redundancy\fP |
| 162 |
The minimum number of backups that should always be available. |
| 163 |
.TP |
| 164 |
.B \fB\-r\fP / \fB\-\-retention\-policy\fP |
| 165 |
If specified, delete all backups eligible for deletion according to the supplied |
| 166 |
retention policy. |
| 167 |
.sp |
| 168 |
Syntax: \fBREDUNDANCY value | RECOVERY WINDOW OF value { DAYS | WEEKS | MONTHS }\fP |
| 169 |
.TP |
| 170 |
.B \fB\-\-batch\-size\fP |
| 171 |
The maximum number of objects to be deleted in a single request to the cloud provider. |
| 172 |
If unset then the maximum allowed batch size for the specified cloud provider will be |
| 173 |
used (\fB1000\fP for aws\-s3, \fB256\fP for azure\-blob\-storage and \fB100\fP for |
| 174 |
google\-cloud\-storage). |
| 175 |
.TP |
| 176 |
.B \fB\-\-dry\-run\fP |
| 177 |
Find the objects which need to be deleted but do not delete them. |
| 178 |
.UNINDENT |
| 179 |
.sp |
| 180 |
\fBExtra options for the AWS cloud provider\fP |
| 181 |
.INDENT 0.0 |
| 182 |
.TP |
| 183 |
.B \fB\-\-check\-object\-lock\fP |
| 184 |
Check whether backup files are protected by S3 Object Lock before attempting |
| 185 |
deletion. Enable this when your S3 bucket has Object Lock configured and you |
| 186 |
want to ensure deletion operations respect object\-level retention policies. If |
| 187 |
any base backup file is locked (either by an active retention period or legal |
| 188 |
hold), the deletion is aborted with an error. |
| 189 |
.sp |
| 190 |
For performance reasons, lock checks are only performed for base backup files, |
| 191 |
since once the base backup is removed, the corresponding WAL files are no longer |
| 192 |
useful. Note that this check requires one request per file to check the lock |
| 193 |
status, which may increase deletion time for backups with many files. This feature |
| 194 |
is only available for AWS S3\-compatible object stores and it also requires the |
| 195 |
\fBs3:GetObjectRetention\fP and \fBs3:GetObjectLegalHold\fP IAM permissions. |
| 196 |
.TP |
| 197 |
.B \fB\-\-endpoint\-url\fP |
| 198 |
Override default S3 endpoint URL with the given one. |
| 199 |
.TP |
| 200 |
.B \fB\-\-addressing\-style\fP |
| 201 |
The addressing style to use for S3 requests. This is useful when connecting to |
| 202 |
S3\-compatible services that require a specific addressing style. |
| 203 |
.sp |
| 204 |
Allowed options are: |
| 205 |
.INDENT 7.0 |
| 206 |
.IP \(bu 2 |
| 207 |
\fBauto\fP (default): Uses the addressing style determined by the underlying library. |
| 208 |
.IP \(bu 2 |
| 209 |
\fBvirtual\fP: Uses virtual\-hosted style addressing (e.g., bucket\-name.s3.amazonaws.com). |
| 210 |
.IP \(bu 2 |
| 211 |
\fBpath\fP: Uses path\-style addressing (e.g., s3.amazonaws.com/bucket\-name). |
| 212 |
.UNINDENT |
| 213 |
.TP |
| 214 |
.B \fB\-P\fP / \fB\-\-aws\-profile\fP |
| 215 |
Profile name (e.g. \fBINI\fP section in AWS credentials file). |
| 216 |
.TP |
| 217 |
.B \fB\-\-profile\fP (deprecated) |
| 218 |
Profile name (e.g. \fBINI\fP section in AWS credentials file) \- replaced by |
| 219 |
\fB\-\-aws\-profile\fP\&. |
| 220 |
.TP |
| 221 |
.B \fB\-\-read\-timeout\fP |
| 222 |
The time in seconds until a timeout is raised when waiting to read from a connection |
| 223 |
(defaults to \fB60\fP seconds). |
| 224 |
.TP |
| 225 |
.B \fB\-\-sse\-customer\-key\fP |
| 226 |
The customer\-provided encryption key (SSE\-C) to use for decrypting data in S3. The |
| 227 |
value must be a \fBfile://\fP URI pointing to a file containing a base64\-encoded 256\-bit |
| 228 |
(32\-byte) key (e.g. \fBfile:///etc/barman/sse\-c.b64\fP). |
| 229 |
.sp |
| 230 |
\fBImportant:\fP |
| 231 |
.INDENT 7.0 |
| 232 |
.INDENT 3.5 |
| 233 |
All backups and WAL files for a given server must be encrypted with the same SSE\-C |
| 234 |
key. Mixing SSE\-C\-encrypted and unencrypted objects, or using different keys across |
| 235 |
backups, will cause barman commands to fail when S3 rejects requests with a |
| 236 |
mismatched or missing key. |
| 237 |
.UNINDENT |
| 238 |
.UNINDENT |
| 239 |
.UNINDENT |
| 240 |
.sp |
| 241 |
\fBExtra options for the Azure cloud provider\fP |
| 242 |
.INDENT 0.0 |
| 243 |
.TP |
| 244 |
.B \fB\-\-azure\-credential / \-\-credential\fP |
| 245 |
Optionally specify the type of credential to use when authenticating with Azure. If |
| 246 |
omitted then Azure Blob Storage credentials will be obtained from the environment and |
| 247 |
the default Azure authentication flow will be used for authenticating with all other |
| 248 |
Azure services. If no credentials can be found in the environment then the default |
| 249 |
Azure authentication flow will also be used for Azure Blob Storage. |
| 250 |
.sp |
| 251 |
Allowed options are: |
| 252 |
.INDENT 7.0 |
| 253 |
.IP \(bu 2 |
| 254 |
\fBazure\-cli\fP\&. |
| 255 |
.IP \(bu 2 |
| 256 |
\fBmanaged\-identity\fP\&. |
| 257 |
.IP \(bu 2 |
| 258 |
\fBdefault\fP\&. |
| 259 |
.UNINDENT |
| 260 |
.UNINDENT |
| 261 |
.SH Author |
| 262 |
EnterpriseDB |
| 263 |
.SH Copyright |
| 264 |
© Copyright EnterpriseDB UK Limited 2011-2026 |
| 265 |
.\" End of generated man page. |