pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: basti <mailinglist@unix-solution.de>
To: pgsql-general <pgsql-general@postgresql.org>
Subject: DB Backup from WAL Slave
Date: Tue, 24 Jul 2018 14:44:45 +0200
Message-ID: <c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de> (raw)

Hello,

we have a db master and a slave.

master conf:

wal_level = replica
max_wal_senders = 5
wal_keep_segments = 100
archive_mode    = on
archive_command = 'rsync -a %p -e "ssh -i
/var/lib/postgresql/.ssh/id_rsa"
postgres@slave:/var/lib/postgresql/9.6/wals/master/%f </dev/null'

slave conf:

# replication
hot_standby = on

# pg_dump: Error message from server: ERROR:  canceling statement due to
conflict with recovery
# DETAIL:  User was holding a relation lock for too long.
#
https://www.postgresql.org/message-id/CADp-Sm6if-z0NbsxrJwPBQDQNt6AQJpbbagHbWyGrN7zyYZdCA%40mail.gma...
max_standby_streaming_delay = 300000


The slave is not used as read-only
But as docu say
(https://www.postgresql.org/docs/9.6/static/runtime-config-wal.html)
wal_level = archive is mapped to replica

How can I do an backup with pg_dumpall from slave?

Best Regards,





view thread (4+ messages)  latest in thread

Message-ID: <c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de>
Permalink:  ../c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de/
Also on:    postgresql.org/message-id/c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: mailinglist@unix-solution.de
  Subject: Re: DB Backup from WAL Slave
  In-Reply-To: <c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de>
  References: <c5b4fbe7-cd5b-b703-8304-119415572c9a@unix-solution.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox