pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ruth Melendo <rmelendo@teltronic.es>
To: pgsql-general@postgresql.org
To: pgsql-admin@postgresql.org
Subject: how to recovery your database when stops replicating
Date: Mon, 16 Mar 2015 15:51:47 +0100
Message-ID: <003501d05ff8$ba349240$2e9db6c0$@teltronic.es> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>

Hi all,

 

I´m testing BDR and have a big deal. When it gets corrupted, after time of
working well, I cannot do a recovery and the only way to get the system
working again seems to reset all again. It means:

 

-          Stop all nodes.

-          Delete data directories in both nodes

-          Comment BDR entries in postgresql.conf in node A.

-          Start node A and restore database.

-          Uncomment BDR entries in node A.

-          Start node B with BDR entries so that executes initial copy.

-          It works again.

 

I think there should be a better way to do it. I have some mails from here
telling this:

 

-          Execute this sql in both nodes:

 

SELECT slot_name, datoid, database, active FROM pg_replication_slots WHERE
slot_name LIKE 'bdr_'||(SELECT oid FROM pg_database WHERE datname =
current_database())||'_%';

 

-          Execute this sql to be able to DDL again:

COPY (SELECT * FROM
pg_logical_slot_get_binary_changes('bdr_17911_6120567807158814813_1_16385__'
, NULL, 1, 'interactive', 'true')) TO '/dev/null';

 

-          Reconnect  and do this:

SET bdr.skip_ddl_replication = on;

 

 

But that method don´t work for me. Any help? How do you recovery your
database when stops replicating?

 

Thanks in advance

 

Ruth Patricia Melendo Ventura

Software Engineer

TELTRONIC, S.A.U.

T: +34 976 465656   Ext. 179

F: +34 976 465722 

 <http://www.teltronic.es/; www.teltronic.es

 

Logo40

 

Before printing this e-mail please consider your environmental
responsibility. 

*****  DISCLAIMER  *****

This message is intended exclusively for the named person. It may contain
confidential, propietary or legally privileged information. No
confidentiality or privilege is waived or lost by any mistransmission. If
you receive this message in error, please immediately delete it and all
copies of it from your system, destroy any hard copies of it and notify the
sender. Your must not, directly or indirectly, use, disclose, distribute,
print, or copy any part of this message if you are not the intended
recipient. Any views expressed in this message are those of the individual
sender, except where the message states otherwise and the sender is
authorised to state them to be the views of TELTRONIC. If the addressee of
this message does not consent to the use of internet e-mail, please
communicate it to us immediately.

 

Attachments:

image002.jpg (image/jpeg, 1.6K) download view image

Message-ID: <003501d05ff8$ba349240$2e9db6c0$@teltronic.es>
Permalink:  ../003501d05ff8$ba349240$2e9db6c0$@teltronic.es/
Also on:    postgresql.org/message-id/003501d05ff8$ba349240$2e9db6c0$@teltronic.es

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: rmelendo@teltronic.es, pgsql-general@postgresql.org
  Subject: Re: how to recovery your database when stops replicating
  In-Reply-To: <003501d05ff8$ba349240$2e9db6c0$@teltronic.es>

* 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