barman-cli - which exact commands are being triggered on the pg host?

5 views
Skip to first unread message

dulh...@mailbox.org

unread,
May 6, 2022, 12:19:19 PM5/6/22
to pgba...@googlegroups.com
In the paper I am writing on Barman vs pgBackRest I say something like:
"A PostgreSQL Cluster backed up via Barman requires barman-cli to be installed.
barman-cli is a selection of commands which are executed on the PostgreSQL Server when a Barman operation is started on the Barman Backup host"
Now I would like to give one or two examples for such Barman commands. Can anybody help me out here?

Michael Wallace

unread,
May 9, 2022, 4:49:46 AM5/9/22
to pgba...@googlegroups.com
barman-cli isn't required by Barman in order to perform backup and recovery but it can be very helpful - the two commands are documented in the manual, specifically:
  • barman-wal-archive - this can be used as PostgreSQL's archive_command instead of rsync. The main reason for doing so is that barman-wal-archive will not just copy the WAL to the Barman server but it will also ensure it is flushed to disk using fsync. If plain rsync is used then the WAL may remain in a cache on the Barman server and not be flushed to disk until after archive_command has returned successfully.
  • barman-wal-restore - this can be used as PostgreSQL's restore_command and is added to the recovery options when `get-wal` is specified in recovery_options *and* a remote recovery is requested via the --remote-ssh-command option. This allows PostgreSQL to fetch the WALs required for point-in-time recovery without requiring Barman to copy the WALs to the PostgreSQL server during the recovery process.
If barman-cli isn't installed on the PostgreSQL server then backup and restore are still possible however:
  1. WAL archive can only be performed using rsync directly.
  2. WALs cannot be fetched from a remote Barman server during recovery and are instead copied to the PostgreSQL server during the `barman recover` command.
Hope this helps.

--
--
You received this message because you are subscribed to the "Barman for PostgreSQL" group.
To post to this group, send email to pgba...@googlegroups.com
To unsubscribe from this group, send email to
pgbarman+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/pgbarman?hl=en?hl=en-GB

---
You received this message because you are subscribed to the Google Groups "Barman, Backup and Recovery Manager for PostgreSQL" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pgbarman+u...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/pgbarman/d0dfbad6-b3bc-fdf0-7b66-5306123a3f9d%40mailbox.org.
Reply all
Reply to author
Forward
0 new messages