Hello, Assuming we have two (low traffic) servers (on different data centers) replicated using dsync, what is the best way to automatically direct users to the main server when it is up and to the redundant one when the main server is down? Using DNS? I've seen that DNS-based failover has generally issues (for example: http://serverfault.com/questions/60553/why-is-dns-failover-not-recommended, which is informative although it refers to web servers). What is the suggested approach? HAProxy? Heartbeat/Pacemaker? Any advice will be appreciated. Thanks and regards, Nick
On 19.4.2013, at 9.59, Nikolaos Milas <nmilas at noa.gr> wrote:> Assuming we have two (low traffic) servers (on different data centers) replicated using dsync, what is the best way to automatically direct users to the main server when it is up and to the redundant one when the main server is down? > > Using DNS? I've seen that DNS-based failover has generally issues (for example: http://serverfault.com/questions/60553/why-is-dns-failover-not-recommended, which is informative although it refers to web servers). > > What is the suggested approach? HAProxy? Heartbeat/Pacemaker?Well, there are two failure reasons: a) Dovecot server fails. For that, you could use any kind of a proxy that redirects traffic to the other server (even Dovecot proxy on another server). b) Network connection to the whole data center dies, or the whole data center loses power or otherwise dies. There's really no other choice to failover that than DNS, unless you manage to route the same IP address to two different data centers and just update the route. I'd be more worried about b), since you can already fix a) pretty quickly with VMs. Or a) could also be switched to become a Dovecot proxy on demand if there's a bigger problem that can't be immediately fixed.
Am 19.04.2013 08:59, schrieb Nikolaos Milas:> Hello, > > Assuming we have two (low traffic) servers (on different data centers) > replicated using dsync, what is the best way to automatically direct > users to the main server when it is up and to the redundant one when the > main server is down? > > Using DNS? I've seen that DNS-based failover has generally issues (for > example: > http://serverfault.com/questions/60553/why-is-dns-failover-not-recommended, > which is informative although it refers to web servers). > > What is the suggested approach? HAProxy? Heartbeat/Pacemaker?i run keepalived as loadbalancer/failover but pacemaker etc should work fine too> > Any advice will be appreciated. > > Thanks and regards, > Nick > > > >Best Regards MfG Robert Schetterer -- [*] sys4 AG http://sys4.de, +49 (89) 30 90 46 64 Franziskanerstra?e 15, 81669 M?nchen Sitz der Gesellschaft: M?nchen, Amtsgericht M?nchen: HRB 199263 Vorstand: Patrick Ben Koetter, Axel von der Ohe, Marc Schiffbauer Aufsichtsratsvorsitzender: Joerg Heidrich