Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Installing postfix with mysql

103 views
Skip to first unread message

Scott Brown

unread,
Mar 7, 2012, 6:46:25 PM3/7/12
to
Hello,
I am trying to install Postfix with mysql on CentOS 6.0.

I am trying to follow the instructions at http://www.postfix.org/MYSQL_README.html

I downloaded the mysql libraries and source code.

The libmysql was extracted to /usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit

So from the postfix-2.9.1 directory, I ran:
make -f Makefile.init makefiles \
    'CCARGS=-DHAS_MYSQL
-I/usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit/include' \
    'AUXLIBS=-L/usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit/lib
-lmysqlclient -lz -lm'

Then ran the make command

When I try to run make install, I get this error:
bin/postconf: error while loading shared
libraries: libmysql.so.16: cannot open shared object file: No such file or
directory 

I found an article online (http://webhostingneeds.com/Error_while_loading_shared_libraries:_libmysqlclient.so.16)  that suggests the /usr/lib/mysql path needs to be added to ld.so.conf, so I did that.  I also created a symlink called libmysql.so.16 in that folder which points to libmysqlclient.so.16 (I did not actually have a file called libmysql.so.16).

I am getting the impression libmysql is different from libmysqlclient.  But I don't see where I can get this "libmysql" package.  I tried "yum install libmysql" but it said there was no package available.

Any help would be greatly appreciated!

Thank you

Scott Brown

Reindl Harald

unread,
Mar 7, 2012, 6:55:01 PM3/7/12
to


Am 08.03.2012 00:46, schrieb Scott Brown scott...@yahoo.com:
> Hello,
> I am trying to install Postfix with mysql on CentOS 6.0.
> I am trying to follow the instructions at http://www.postfix.org/MYSQL_README.html
> I downloaded the mysql libraries and source code.

why?

"yum install mysql-devel"

> The libmysql was extracted to /usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit

AFAIK this is not mysql-devel

> When I try to run make install, I get this error:
> bin/postconf: error while loading shared
> libraries: libmysql.so.16: cannot open shared object file: No such file or
> directory

use as much system-packages as you can in as much default locations as possible!

signature.asc

Scott Brown

unread,
Mar 7, 2012, 6:59:01 PM3/7/12
to
I want to use MySQL to manage the virtual table within Postfix. So it's not that I want to just have MySQL and Postfix on the server as separate applications.  I want the MySQL-enhanced version of Postfix.

Mailinglist

unread,
Mar 7, 2012, 7:17:31 PM3/7/12
to
CentOS Plus repo already has the postfix-SQL rpm. Go into /etc/yum.repo/CentOS.repo file and exclude postfix under Base and Updates. Then run yum --enablerepo=centosplus install postfix - this will install the version you need without having to compile.

Regards

Mailinglist

unread,
Mar 7, 2012, 7:21:25 PM3/7/12
to
I don't know what you use but on my iPad / iPhone if I hit reply it only sends to you not the list. I do reply all. Please stop the whine and be constructive. Kthx

Regards

On Mar 7, 2012, at 7:08 PM, Reindl Harald <h.re...@thelounge.net> wrote:

> also fixed the offlist-reply
>
> jesus christ do not answer on top if you got
> one below your post and there is no need to
> send a "reply-all" because people answering
> on the mailing-list wilöl get also your reply
> on the list
>
> -------- Original-Nachricht --------
> Betreff: Re: Installing postfix with mysql
> Datum: Thu, 08 Mar 2012 01:04:50 +0100
> Von: Reindl Harald <h.re...@thelounge.net>
> Organisation: the lounge interactive design
> An: Scott Brown <scott...@yahoo.com>
>
> TOP-POSTING FIXED
>
>> ----- Original Message -----
>> From: Reindl Harald <h.re...@thelounge.net>
>> To: postfi...@postfix.org
>> Cc:
>> Sent: Wednesday, March 7, 2012 6:55 PM
>> Subject: Re: Installing postfix with mysql
>>
>>
>>
>> Am 08.03.2012 00:46, schrieb Scott Brown scott...@yahoo.com:
>>> Hello,
>>> I am trying to install Postfix with mysql on CentOS 6.0.
>>> I am trying to follow the instructions at http://www.postfix.org/MYSQL_README.html
>>> I downloaded the mysql libraries and source code.
>>
>> why?
>>
>> "yum install mysql-devel"
>>
>>> The libmysql was extracted to /usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit
>>
>> AFAIK this is not mysql-devel
>>
>>> When I try to run make install, I get this error:
>>> bin/postconf: error while loading shared
>>> libraries: libmysql.so.16: cannot open shared object file: No such file or
>>> directory
>>
>> use as much system-packages as you can in as much default locations as possible!
>
> Am 08.03.2012 00:59, schrieb Scott Brown scott...@yahoo.com:
>> I want to use MySQL to manage the virtual table within Postfix.
>> So it's not that I want to just have MySQL and Postfix on the server as
>> separate applications. I want the MySQL-enhanced version of Postfix.
>
> i can not really imagine what you mean!
>
> if you want to compile any application on a Redhat based OS
> against mysql you simply install "mysql-devel" with it's dependencies
> instead download any random crap and move it somewhere
>
> after that you compile your application with the options to
> enable mysql-support, that is at the first step all you need
>
> so you have a clean setup and postfix is working with mysql-support
> where your database lives is another story, that is defined
> in your configuration
>
>> So it's not that I want to just have MySQL and Postfix on the server as
>> separate applications.
>
> how do you imagine this?
>
> somewhere has to be installed a normal mysqld to which postfix
> connects - ther is no "hey i am postfix and i am am MTA and
> database server at the same time"
>
> this are two complete different applications and will be all the time
>
>
>
> --
>
> Mit besten Grüßen, Reindl Harald
> the lounge interactive design GmbH
> A-1060 Vienna, Hofmühlgasse 17
> CTO / software-development / cms-solutions
> p: +43 (1) 595 3999 33, m: +43 (676) 40 221 40
> icq: 154546673, http://www.thelounge.net/
>
> http://www.thelounge.net/signature.asc.what.htm
>

Reindl Harald

unread,
Mar 7, 2012, 7:39:16 PM3/7/12
to


Am 08.03.2012 01:21, schrieb Mailinglist maili...@theflux.net:
> I don't know what you use but on my iPad / iPhone if I hit reply it only
> sends to you not the list. I do reply all. Please stop the whine and be
> constructive. Kthx

if your client is broken and does not support "reply to list"
you culd be so nice and remove the personal RCPT after press
"reply all"

i do not whine but I MAFDE A MISTAKE use reply off-list because
first i got the duplicate and after reply the message to the
list - nobody needs each message multiple times

the same for top-posting AFTER get a reply below the OP
a thread is completly unreadable this way if questions
and anserws are miexed in randomly order

signature.asc

Tomoyuki Murakami

unread,
Mar 7, 2012, 8:17:10 PM3/7/12
to

On Wed, 7 Mar 2012 15:46:25 -0800 (PST), Scott Brown <scott...@yahoo.com> wrote:

> I am trying to install Postfix with mysql on CentOS 6.0.
> I am trying to follow the instructions at http://www.postfix.org/MYSQL_README.html
> I downloaded the mysql libraries and source code.
> The libmysql was extracted to /usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit
>
> So from the postfix-2.9.1 directory, I ran:
> make -f Makefile.init makefiles \
>     'CCARGS=-DHAS_MYSQL
> -I/usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit/include' \
>     'AUXLIBS=-L/usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit/lib
> -lmysqlclient -lz -lm'

Actually, I don't know the compatibility of libmysql with
libmysqlclient, did you tried 'ldconfig' after installed that
library ?
or, you should use MySQL-devel-....rpm in order to follow
the README instructions safely.

> Then ran the make command
>
> When I try to run make install, I get this error:
> bin/postconf: error while loading shared
> libraries: libmysql.so.16: cannot open shared object file: No such file or
> directory 

you should check
# ldd bin/postconf
(in Linux) or something like that after this kind of errors.

Scott Brown

unread,
Mar 12, 2012, 6:52:46 PM3/12/12
to
That worked! Thank you very much!


From: Mailinglist <maili...@theflux.net>
To: Scott Brown <scott...@yahoo.com>
Cc: Reindl Harald <h.re...@thelounge.net>; "postfi...@postfix.org" <postfi...@postfix.org>
Sent: Wednesday, March 7, 2012 7:17 PM

Subject: Re: Installing postfix with mysql

CentOS Plus repo already has the postfix-SQL rpm. Go into /etc/yum.repo/CentOS.repo file and exclude postfix under Base and Updates. Then run yum --enablerepo=centosplus install postfix - this will install the version you need without having to compile.

Regards


On Mar 7, 2012, at 6:59 PM, Scott Brown <scott...@yahoo.com> wrote:

> I want to use MySQL to manage the virtual table within Postfix. So it's not that I want to just have MySQL and Postfix on the server as separate applications.  I want the MySQL-enhanced version of Postfix.
>
>
> ----- Original Message -----
> From: Reindl Harald <h.re...@thelounge.net>
> To: postfi...@postfix.org
> Cc:
> Sent: Wednesday, March 7, 2012 6:55 PM
> Subject: Re: Installing postfix with mysql
>
>
>
> Am 08.03.2012 00:46, schrieb Scott Brown scott...@yahoo.com:
>> Hello,
>> I am trying to install Postfix with mysql on CentOS 6.0.
>> I am trying to follow the instructions at http://www.postfix.org/MYSQL_README.html
>> I downloaded the mysql libraries and source code.
>
> why?
>
> "yum install mysql-devel"

>
>> The libmysql was extracted to /usr/local/mysql-connector-c-6.0.2-linux-glibc2.3-x86-32bit
>
> AFAIK this is not mysql-devel
>
>> When I try to run make install, I get this error:
>> bin/postconf: error while loading shared
>> libraries: libmysql.so.16: cannot open shared object file: No such file or
>> directory
>
0 new messages