[Exim] Problem with Exim+MySQL

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Paul Walsh
Date:  
À: Exim Users
Sujet: [Exim] Problem with Exim+MySQL
As a prelude to using MySQL lookups I've recompiled Exim to include MySQL
support. I have the following in Local/Makefile:

LOOKUP_MYSQL=yes
LOOKUP_INCLUDE=-I /usr/local/mysql/include/mysql
LOOKUP_LIBS=-L/usr/local/lib -lmysqlclient -lz

Exim was compiled successfully so I installed the binary, killed off any
existing exim processes and started a new one. Note that at this stage I
haven't made any changes to the config file as I'm still using DBM lookups.
Unfortunately, the newly installed binary quite happily accepts messages and
queues them but no deliveries appear to be taking place. As root I can
force delivery of a message without problem so I figured it must be
something to do with the exim user's environment. Sure enough, if I login
as user exim and try exim -bpu I get the following:
$ exim -bpu
ld.so.1: exim: fatal: libmysqlclient.so.10: open failed: No such file or
directory
Killed

What I can't figure out is why this message is coming up.
libmysqlclient.so.10 is installed in /usr/local/lib and exim's
LD_LIBRARY_PATH is set with /usr/local/lib being first in the chain.
Permissions on /usr/local and /usr/local/lib are 755 so exim _should_ be
able to see the library. I've even copied root's .profile in place but exim
still can't find the library, yet if I type in mysql while logged in as
exim I get

$ mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 157 to server version: 3.23.39-log

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>

Any ideas (or can't I see the wood for the trees)?

O/S:        Solaris 2.6
Exim:        3.32
gcc:        2.95.3 20010315 (release)
MySQL:    3.23.39


Paul Walsh

Senior Systems Administrator, Information Services,
University of Central England, BIRMINGHAM B42 2SU, UK
Tel: +44 (0)121 331 5708    Fax: +44 (0)121 356 2875