2ndQuadrant | PostgreSQL
PostgreSQL Solutions for the Enterprise
+39 0574 159 3000
  • Contact Us
  • EN
    • FR
    • IT
    • ES
    • DE
  • Support & Services
    • Support
      • 24/7 PostgreSQL Support
      • Developer Support
      • IBM Z Production Support
    • DBA Services
      • Remote DBA
      • Database Monitoring
    • Consulting Services
      • Health Check
      • Performance Tuning
      • Database Security Audit
      • PostgreSQL Upgrade
      • Kubernetes for Postgres and BDR
    • Migration Services
      • Migrate to PostgreSQL
      • Migration Assessment
  • Products
    • PostgreSQL with High Availability
    • BDR
    • 2ndQPostgres
    • pglogical
      • Installation instruction for pglogical
      • Documentation
    • repmgr
    • Barman
    • Postgres Cloud Manager
    • SQL Firewall
    • Postgres-XL
    • OmniDB
    • Postgres Installer
    • 2UDA
  • Downloads
    • Postgres Installer
    • 2UDA – Unified Data Analytics
  • Postgres Learning Center
    • Webinars
      • You forgot to put the WHERE in DELETE?
      • BDR Overview
    • Whitepapers
      • Highly Available Postgres Clusters
      • AlwaysOn Postgres
      • BDR
      • PostgreSQL Security Best Practices
    • Case Studies
      • Performance Tuning
        • BenchPrep
        • tastyworks
      • Distributed Clusters
        • ClickUp
        • European Space Agency (ESA)
        • Telefónica del Sur
        • Animal Logic
      • Database Administration
        • Agilis Systems
      • Professional Training
        • Met Office
        • London & Partners
      • Database Upgrades
        • Alfred Wegener Institute (AWI)
      • Database Migration
        • Healthcare Software Solutions (HSS)
        • Navionics
    • Training
      • Training Catalog and Scheduled Courses
        • Advanced Development & Performance
        • Linux for PostgreSQL DBAs
        • BDR
        • PostgreSQL Database Administration
        • PostgreSQL Data Warehousing & Partitioning
        • PostgreSQL for Developers
        • PostgreSQL Immersion
        • PostgreSQL Immersion for Cloud Databases
        • PostgreSQL Security
        • Postgres-XL-10
        • Practical SQL
        • Replication, Backup & Disaster Recovery
        • Introduction to PostgreSQL and Kubernetes
    • Books
      • PostgreSQL 11 Administration Cookbook
      • PostgreSQL 10 Administration Cookbook
      • PostgreSQL High Availability Cookbook – 2nd Edition
      • PostgreSQL 9 Administration Cookbook – 3rd Edition
      • PostgreSQL Server Programming Cookbook – 2nd Edition
      • PostgreSQL 9 Cookbook – Chinese Edition
    • PostgreSQL
      • PostgreSQL – History
      • Who uses PostgreSQL?
      • PostgreSQL FAQ
      • PostgreSQL vs MySQL
      • Business Case for PostgreSQL
      • Security Information
    • Events
    • Blog
  • About Us
    • About 2ndQuadrant
    • What Does “2ndQuadrant” Mean?
    • 2ndQuadrant’s Passion for PostgreSQL
    • Ask Simon
    • News
    • Careers
    • Team Profile
  • Blog
  • Menu
You are here: Home / Blog / Barman / Managing the backup of several PostgreSQL servers with Barman
Gabriele Bartolini

Managing the backup of several PostgreSQL servers with Barman

December 4, 2012/2 Comments/in Barman, Gabriele's PlanetPostgreSQL /by Gabriele Bartolini

One of the key aspects of Barman is the possibility to remotely backup multiple PostgreSQL servers from one single backup host. The upcoming version 1.1.2 of Barman will make this much easier from a system administrator’s point of view. Let’s see why.

With Barman you can use the backup host as a simple backup server, and simply store backup data regarding different PostgreSQL version servers. Or plan to use it for recovery as well (local recovery). In this case you need to install every PostgreSQL version for which you need to perform local recovery.

In these first 5 months of Barman’s life, we have received a few requests from users (mainly system administrators) around the world asking to simplify the management of backups for several databases. My personal opinion is that this use case is typical of hosting companies or big organisations.

The upcoming 1.1.2 release of Barman will include the so called configuration files directory setting, which allows system administrators and DBAs to specify a directory that will contain server directives. For example, you can define in Barman’s global configuration section the following option:

configuration_files_directory = /etc/barman.d

This option will make Barman look for *.conf files in that directory and evaluate them on the fly. Suppose you have to manage the backup of 6 or more PostgreSQL instances, you can specify a different file for each of those instances and name it in a meaningful way:

|- /etc
  |- barman.d
    |- 01-angus.conf
    |- 02-malcolm.conf
    |- 03-bon.conf.disabled
    |- 04-brian.conf
    |- 05-phil.conf
    |- 06-chris.conf
    |- ...

Then specify a server configuration in /etc/barman.d/01-angus.conf:

[angus]
description = Angus Rocks
ssh_command = ssh angus
conninfo = host=angus port=5432 user=postgres dbname=postgres

Adding a new server or disabling/removing a server becomes as trivial as adding a new file or renaming it.

If you type “barman list-server” you get:

angus - Angus Rocks
brian - Brian screams
chris - Chris on the bass
...

This behaviour is quite spread on Linux applications and allows to improve the integration of Barman with configuration managers such as Puppet.

More information on this feature is available in the online documentation of Barman, in the basic configuration section.

Another interesting feature added in version 1.1.2 is the shortcut ID for backups. Barman now manages shortcut aliases for backup identifiers such as latest/last or oldest/first.

This means that you can now type “barman delete SERVER_ID oldest” and easily delete the oldest backup available for that server, or type “barman show-backup SERVER_ID latest” to get information about the latest backup available for that server. Cool, isn’t it? 😉

So, stay tuned for version 1.1.2! Ciao!

Tags: Barman, configuration files directory, disaster recovery, hosting, Linux, puppet, system administration, unix
Share this entry
  • Share on Facebook
  • Share on Twitter
  • Share on WhatsApp
  • Share on LinkedIn
2 replies
  1. GC
    GC says:
    December 4, 2012 at 6:59 pm

    You cannot have 03-bon.conf at the same time as 04-brian.conf !

    Reply
    • Gabriele Bartolini
      Gabriele Bartolini says:
      December 4, 2012 at 7:26 pm

      Yeah, you right, it is another timeline. I will have to rename 03-bon.conf into 03-bon.conf.disabled

      Reply

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Search

Recent Posts

  • Setting SSL/TLS protocol versions with PostgreSQL 12 November 27, 2019
  • Webinar: Using SSL with PostgreSQL and pgbouncer [Follow Up] November 14, 2019
  • PostgreSQL 12: Implementing K-Nearest Neighbor Space Partitioned Generalized Search Tree Indexes November 5, 2019
  • Webinar: PostgreSQL Partitioning [Follow up] October 28, 2019
  • Postgres-BDR: It is also about fast safe upgrades October 15, 2019

Featured External Blogs

Tomas Vondra's Blog

Our Bloggers

  • Simon Riggs
  • Alvaro Herrera
  • Andrew Dunstan
  • Craig Ringer
  • Francesco Canovai
  • Gabriele Bartolini
  • Giulio Calacoci
  • Ian Barwick
  • Marco Nenciarini
  • Mark Wong
  • Pavan Deolasee
  • Petr Jelinek
  • Shaun Thomas
  • Tomas Vondra
  • Umair Shahid

PostgreSQL Cloud

2QLovesPG 9.6 backup Barman BDR Business Continuity community conference database DBA development devops disaster recovery greenplum Hot Standby JSON JSONB kanban logical decoding logical replication monitoring open source performance PG12 pgbarman pgday pglogical PG Phriday postgres Postgres-BDR postgres-xl PostgreSQL PostgreSQL 9.6 PostgreSQL10 PostgreSQL 11 PostgreSQL11 PostgreSQL 11 New Features postgresql repmgr Recovery release replication sql standby wal webinar
UK +44 (0)870 766 7756

US +1 650 378 1218

Support & Services

24/7 Production Support

Developer Support

Remote DBA for PostgreSQL

PostgreSQL Database Monitoring

PostgreSQL Health Check

PostgreSQL Performance Tuning

Database Security Audit

Upgrade PostgreSQL

PostgreSQL Migration Assessment

Migrate from Oracle to PostgreSQL

Products

HA Postgres Clusters

Postgres-BDR

2ndQPostgres

pglogical

repmgr

Barman

Postgres Cloud Manager

SQL Firewall

Postgres-XL

OmniDB

Postgres Installer

2UDA

Postgres Learning Center

Introducing Postgres

Blog

Webinars

Books

Videos

Training

Case Studies

Events

About Us

About 2ndQuadrant

What does 2ndQuadrant Mean?

News

Careers 

Team Profile

©2001-2019 2ndQuadrant Ltd. All rights reserved | Privacy Policy
  • Twitter
  • LinkedIn
  • Facebook
  • Youtube
  • Mail
79 real attendees at the Italian PGDay Barman 1.1.2 released
Scroll to top
×