pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: soumitra bhandary <soumitra.bhandary@hotmail.com>
To: shreeyansh2014@gmail.com <shreeyansh2014@gmail.com>
To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>
Subject: Configuration of django with master slave replication Postgres
Date: Tue, 2 Apr 2019 11:50:25 +0000
Message-ID: <MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM> (raw)


Hi
Does anyone have any idea with django how to configure multiple dsn that will automatically switch to new Postgres master host in case of failover happens to previous master and auto promotion of new master is done with repmgr.


My configuration is as below 

Master and asynchronous slave node . Repmgrd is configured to take care of autofailover and promotion of new master node.

But from application side with django how to make datasource so that it automatically switches to new master node in case of failover. 
Please share the steps.


Sent from my iPhone




view thread (6+ messages)  latest in thread

Message-ID: <MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM>
Permalink:  ../MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM/
Also on:    postgresql.org/message-id/MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM

 · 

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-admin@postgresql.org
  Cc: soumitra.bhandary@hotmail.com, shreeyansh2014@gmail.com
  Subject: Re: Configuration of django with master slave replication Postgres
  In-Reply-To: <MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM>
  References: <MA1PR01MB3548E88AC81FF8E528229AFFE0560@MA1PR01MB3548.INDPRD01.PROD.OUTLOOK.COM>

* 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