Autor: W B Hacker Data: Para: exim users Assunto: Re: [exim] mysql (multiple servers)
Peter Bowyer wrote:
> On 10/10/06, W B Hacker <wbh@???> wrote:
>
>>tlabs wrote:
>>
>>>How exactly does the conf of multiple mysql servers work?
>>>Is it as failover style thing or a load balanced algorythm?
>>>
>>>cheers
>>>
>>>
>>
>>Wrong list.
>>
>>This is Exim, an smtp MTA.
>>
>>MySQL is down the hall.......
>
>
> Bill's in an uncharitable mood today and clearly needs coffee -
.. 04:45 Wednesday here in HKG, and just creeping in from Tuesday nite's
meeting, so.... yessss. Coffee would be in order...
> assuming you're referring to the feature of Exim which allows you to
> specify multiple MySQL servers... it's kind-of failover; it definitely
> isn't load-balancing.
ACK.... sorry ... I have spent about 20 more years mucking about with SQL than
with smtp, so jumping to 'general case' assumptions...
>
> If a query fails on the first server, it will be tried on the next and
> then subsequent. The next query will be tried again on the first
> server.
..IOW, there is no 'memory' that server_a is down and server_b should be tried
first next go...
Should be easy enough to set a 'flip-flop' that changes the order with each
request so that they load-balance after a fashion.
>
> 'Fails' covers all kinds of MySQL errors returned from the client
> library, including connection errors, 'no such table' errors, syntax
> errors, etc etc. It specifically excludes a situation where the query
> runs successfully but returns no data - you deal with that in your
> lookup syntax.
>
> Does that help?
>
> Peter
>