Re: [exim] Multiple MySQL db

Top Page
Delete this message
Reply to this message
Author: Peter Bowyer
Date:  
To: exim-users
Subject: Re: [exim] Multiple MySQL db
On Tue, 23 Nov 2004 09:21:05 +0000 (GMT), Philip Hazel
<ph10@???> wrote:
> On Mon, 22 Nov 2004, Peter Bowyer wrote:
>
>
>
> > On Mon, 22 Nov 2004 12:09:50 -0500, Dominic Germain
> > <mailinglists@???> wrote:
> > > Is is possible in a configuration file to use more than MySQL server?
> > >
> > > I want to continue to run all queries on the my locally readonly
> > > replicated db, but I want cumulate some stats in a table to an another
> > > server...
> >
> > Quote both connections in 'mysql_servers'. Make sure you specifiy the
> > database names in the queries.
>
> No, that doesn't do it. The list in mysql_servers is a backup list; it
> only uses the second server if it cannot access the first one


Interesting - that's not my experience - if the first query fails
because of a non-existant db on the connection (as well as because of
a failed connection), it falls back to the second connection. This is
very useful behaviour and can be used to simulate selection of
connections as long as you don't have colliding db names.

I can't test it right now, but when I gave the same advice recently

http://www.exim.org/mailman/htdig/exim-users/Week-of-Mon-20041108/msg00000.html

the person with the problem said that this technique solved it for them....

Peter