EnterpriseDB / barman

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

How can I set parameter statement_timeout in barman backup configuration file ? #915

Open Myshiner opened 8 months ago

Myshiner commented 8 months ago

I got some errors like that "DETAILS: pg_start_backup(): canceling statement due to statement timeout" in backup log file and then backup task failded. so i wonder if i can set the postgresql database parameter "statement_timeout" in backup config file .

Myshiner commented 8 months ago

image

martinmarques commented 8 months ago

You should start by checking here: https://www.postgresql.org/docs/16/libpq-connect.html#LIBPQ-CONNSTRING

barthisrael commented 5 months ago

For the record, you can use options in the connection string, e.g.:

$ psql "host=localhost user=postgres options='-c statement_timeout=10'"
psql (17beta1)
Type "help" for help.

postgres=# SHOW statement_timeout ;
 statement_timeout
-------------------
 10ms
(1 row)
gonzalemario commented 2 months ago

@Myshiner do you need anything else from us?