summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Sharpe2019-02-20 22:25:24 -0800
committerJeff Sharpe2019-02-20 22:25:24 -0800
commitfc3400aa053a378f50cdbc6e0383e1914e228a8d (patch)
treefdb426ea4164c6dda4b160b8abf9635c245c0fb7
parent0d3623064cb057af12e5f1304b2b3171196100e0 (diff)
downloadaur-fc3400aa053a378f50cdbc6e0383e1914e228a8d.tar.gz
Adopt and upgrade to 2.6
-rw-r--r--.gitignore5
-rw-r--r--barman.crond2
-rw-r--r--barman.logrotate5
-rw-r--r--passive-server.conf-template22
-rw-r--r--ssh-server.conf-template42
-rw-r--r--streaming-server.conf-template39
6 files changed, 115 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..0fbf3b8a15b4
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,5 @@
+pkg/
+src/
+*.pkg.tar.xz
+*.tar.gz
+tags
diff --git a/barman.crond b/barman.crond
new file mode 100644
index 000000000000..9d2e3a9c07b3
--- /dev/null
+++ b/barman.crond
@@ -0,0 +1,2 @@
+# m h dom mon dow user command
+ * * * * * barman [ -x /usr/bin/barman ] && /usr/bin/barman -q cron
diff --git a/barman.logrotate b/barman.logrotate
new file mode 100644
index 000000000000..4bb80bac2c3a
--- /dev/null
+++ b/barman.logrotate
@@ -0,0 +1,5 @@
+/var/log/barman/barman.log {
+ missingok
+ notifempty
+ create 0600 barman barman
+}
diff --git a/passive-server.conf-template b/passive-server.conf-template
new file mode 100644
index 000000000000..314762977abd
--- /dev/null
+++ b/passive-server.conf-template
@@ -0,0 +1,22 @@
+; Barman, Backup and Recovery Manager for PostgreSQL
+; http://www.pgbarman.org/ - http://www.2ndQuadrant.com/
+;
+; Template configuration file for a server using
+; SSH connections and rsync for copy.
+;
+
+[passive]
+; Human readable description
+description = "Example of a Barman passive server"
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; Passive server configuration
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+; Local parameter that identifies a barman server as 'passive'.
+; A passive node uses as source for backups another barman server
+; instead of a PostgreSQL cluster.
+; If a primary ssh command is specified, barman will use it to enstabilish a
+; connection with the barman "master" server.
+; Empty by default it can be also set as global value.
+primary_ssh_command = ssh barman@backup
diff --git a/ssh-server.conf-template b/ssh-server.conf-template
new file mode 100644
index 000000000000..d20cf7a6ae1e
--- /dev/null
+++ b/ssh-server.conf-template
@@ -0,0 +1,42 @@
+; Barman, Backup and Recovery Manager for PostgreSQL
+; http://www.pgbarman.org/ - http://www.2ndQuadrant.com/
+;
+; Template configuration file for a server using
+; SSH connections and rsync for copy.
+;
+
+[ssh]
+; Human readable description
+description = "Example of PostgreSQL Database (via SSH)"
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; SSH options (mandatory)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ssh_command = ssh postgres@pg
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; PostgreSQL connection string (mandatory)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+conninfo = host=pg user=barman dbname=postgres
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; Backup settings (via rsync over SSH)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+backup_method = rsync
+; Incremental backup support: possible values are None (default), link or copy
+;reuse_backup = link
+; Identify the standard behavior for backup operations: possible values are
+; exclusive_backup (default), concurrent_backup
+;backup_options = exclusive_backup
+
+; Number of parallel workers to perform file copy during backup and recover
+;parallel_jobs = 1
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; Continuous WAL archiving (via 'archive_command')
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+archiver = on
+;archiver_batch_size = 50
+
+; PATH setting for this server
+;path_prefix = "/usr/pgsql-9.6/bin"
diff --git a/streaming-server.conf-template b/streaming-server.conf-template
new file mode 100644
index 000000000000..75c8cc6f5e76
--- /dev/null
+++ b/streaming-server.conf-template
@@ -0,0 +1,39 @@
+; Barman, Backup and Recovery Manager for PostgreSQL
+; http://www.pgbarman.org/ - http://www.2ndQuadrant.com/
+;
+; Template configuration file for a server using
+; only streaming replication protocol
+;
+
+[streaming]
+; Human readable description
+description = "Example of PostgreSQL Database (Streaming-Only)"
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; PostgreSQL connection string (mandatory)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+conninfo = host=pg user=barman dbname=postgres
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; PostgreSQL streaming connection string
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; To be used by pg_basebackup for backup and pg_receivexlog for WAL streaming
+; NOTE: streaming_barman is a regular user with REPLICATION privilege
+streaming_conninfo = host=pg user=streaming_barman
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; Backup settings (via pg_basebackup)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+backup_method = postgres
+;streaming_backup_name = barman_streaming_backup
+
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+; WAL streaming settings (via pg_receivexlog)
+; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+streaming_archiver = on
+slot_name = barman
+;streaming_archiver_name = barman_receive_wal
+;streaming_archiver_batch_size = 50
+
+; PATH setting for this server
+;path_prefix = "/usr/pgsql-9.6/bin"