RE: [Exim] Problem with multiple mysql servers and queries

Top Page
Delete this message
Reply to this message
Author: Brian K. West
Date:  
To: 'Ganbold', exim-users
Subject: RE: [Exim] Problem with multiple mysql servers and queries
If I recall correctly you must have all the sql servers containing the exact
same info. You can use sever 1 for auth and server 2 for mail routing info.
It don't work like that.

bkw

-----Original Message-----
From: exim-users-admin@??? [mailto:exim-users-admin@exim.org] On Behalf
Of Ganbold
Sent: Monday, May 26, 2003 2:58 AM
To: exim-users@???
Subject: [Exim] Problem with multiple mysql servers and queries

Hi,

I'm using Exim 4.20 and have 3 different mysql servers running on different
hosts.
I tried to configure relay server to authenticate all users to send email.
Unfortunately all authentication fails.
It seems like check $sender_address_domain fails and directly goes to
second query,
but it still uses connection to first mysql server.
It should work in following way: If sender domain is chinggis.com it should
use first query using first mysql connection,
otherwise it should use second mysql server and query.
However it doesn't work.

How can I configure to use second mysql server if first mysql server fails?
Can somebody give me advice and recommendations on this issue?

Following is the snippets of my exim configure.

In the Main section:

mysql_servers = host1/emls/root/xxx : host2/email/mailuser/xxx :
host3/corp/root/xxx
..
In the authenticators section:

cram:
     driver = cram_md5
     public_name = CRAM-MD5


     server_secret = \
        ${if eq{$sender_address_domain}{chinggis.com}\
        {\
                 ${lookup mysql{select plt from usrs where (pq =
'${quote_mysql:$1}' or name = '${quote_mysql:$1}') and plt != ''}}\
        }\
        {\
                 ${lookup mysql{select pwrd from usrs where (id =
'${quote_mysql:$1}') and pwrd != ''}}\
        }\
       }
     server_set_id = $1



thanks in advance,

Ganbold



--

## List details at http://www.exim.org/mailman/listinfo/exim-users Exim
details at http://www.exim.org/ ##