EnterpriseDB / barman

Barman - Backup and Recovery Manager for PostgreSQL
https://www.pgbarman.org/
GNU General Public License v3.0
2.1k stars 193 forks source link

Barman backup all parallel #651

Open abneits opened 2 years ago

abneits commented 2 years ago

My installation :

Actually, my backups are done with barman backup all (great to avoid to create multiple job task) My "problem" is :

i wonder if it's possible to do it in parallel instead of one by one

mikewallace1979 commented 2 years ago

I think adding an option so barman backup all can run in parallel is a great idea.

We'll need to do a little research/experimentation to figure out how best to implement it - the quickest solution is probably to use multiprocessing in the handling of the cli command and make each call to server.backup in a separate process. The tricky part is tracking the state of each backup and handling/reporting failures - we should do something a little friendlier to the user than just joining each backup process until its done.