[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: how to change master in master/slave setup

Quoting Zachary Denison <zacharydenison@yahoo.com>:

> I have a master ldap server with several slaves.  I
> would like to setup a system whereby if the master
> fails, I can without human intervention have one of
> the slaves become the new master.  Is this possible, I
> would appreciate any pointers, or just a link to the
> appropriate docs so I can rtfm.  Thank you.

_IN THEORY_ you could use some IP takeover (such as
'heartbeat') which checks for the dead master. When
the master dies, it restarts the slapd on the designated
slave with a 'master type config file' instead of it's
default (which is a 'slave type config file'). It also
takes over the IP address, so any requests to the (original)
master continues seaming less...

The problem comes when the original master comes back online.
It can't do that automaticly, you need to (somehow) transfer
the new/replaced master (the previos slave) database  files
to the original master, and then restart the slapd's...

With a little scripting, this shouldn't be TO difficult... :)