Installing#
Barman official packages are provided by PGDG. These packages use the default version of Python 3 that comes with the operating system.
There are three packages that make up the suite of Barman features: barman
,
barman-cli
and barman-cli-cloud
.
barman
is the main package and it must be installed.barman-cli
is an optional package that holds thebarman-wal-restore
andbarman-wal-archive
utilites. This package is mandatory if you plan to use those utilities as thearchive_command
orrestore_command
. It must be installed on each Postgres server that is part of the Barman cluster.barman-cli-cloud
is an optional package that holds thebarman-cloud-*
client scripts that you can use to manage backups in a cloud provider. It must be installed on the Postgres servers that you want to back up directly to a cloud provider, bypassing Barman.
Note
Barman packages can be found in several different repositories. We recommend using PGDG repositories because it ensures compatibility, stability and access to the latest updates.
Warning
Do not upgrade Barman using different repositories. By doing so you risk losing your configuration as each source repository provides different packages, which use different configuration layouts.
RHEL-based distributions#
You can install barman
, barman-cli
and barman-cli-cloud
using RPM
packages on RHEL systems as well as on similar RHEL-based systems like
AlmaLinux, Oracle Linux and Rocky Linux.
To begin with the installation, first install the PGDG RPM repository.
Important
The barman-cli-cloud
scripts are part of the barman-cli
package for
RHEL-based distributions from PGDG. Therefore, you only need to install
barman-cli
to use the cloud scripts.
barman#
To install the barman
package. Run as root:
dnf install barman
barman-cli#
To install the barman-cli
package, run as root in the Postgres server:
dnf install barman-cli
Note
If you want to use the barman-cloud utilities as
hook scripts, you
will need to install the barman-cli
package in the Barman server.
Debian-based distributions#
You can install barman
, barman-cli
and barman-cli-cloud
using DEB packages
on Debian systems as well as on Debian-based systems like Ubuntu.
To begin with the installation, install the PGDG APT repository. This depends on your system:
For Debian: PGDG Debian repository.
For Ubuntu: PGDG Ubuntu repository.
Important
The barman-cli-cloud
package is included among the recommended packages when you
install barman-cli
.
Before starting the installation, it’s essential to evaluate your use case. If you
don’t plan to use the barman-cloud client scripts, such as barman-cloud-backup
,
you can skip installing barman-cli-cloud
as a recommended package when
installing barman-cli
. However, if you only intend to use the barman-cloud client
scripts, you can install the barman-cli-cloud
package on its own.
barman#
To install the barman
package. Run as root:
apt install barman
barman-cli#
To install the barman-cli
package, run as root in the Postgres server:
apt install barman-cli
barman-cli-cloud#
To install the barman-cli-cloud
package, run as root in the Postgres server:
apt install barman-cli-cloud
Note
If you want to use the barman-cloud utilities as hook scripts, you will need to install this package in the Barman server.
SLES-based distributions#
You can install barman
on SLES systems by utilizing the packages provided in
the PostgreSQL Zypper Repository.
To begin installation, you will need to add the appropriate repository by following the detailed instructions available on the PGDG SLES Repository Configuration.
The current supported version for installation is SLES 15 SP5.
Important
The barman-cli-cloud
utilities are part of the barman-cli
package for
SLES-based distributions from PGDG. Therefore, you only need to install
barman-cli
to use the cloud scripts.
barman#
To install the barman
package. Run as root:
zypper install barman
barman-cli#
To install the barman-cli
package, run as root in the Postgres server:
zypper install barman-cli
Note
If you want to use the barman-cloud utilities as hook scripts, you will need to install this package in the Barman server.