Oh thanks - but if you use TCP instead of Sockets this should work?

Stefan

Ernesto schrieb:
> Am 11.01.2010 13:25 schrieb Stefan Priebe:
>> I would like to do the auth and rcpt_ok via MySQL. Is there a good way
>> to share the DB Connection? Or do i have to connect to MySQL for each
>> query? If there is a way - where to store the dbh Handle - so that all
>> childs can use it?
>>
> Hi Stefan,
> 
> you should keep the DB connection for a single SMTP request only - I had
> to learn this myself: See the discussion on
> http://www.nntp.perl.org/group/perl.qpsmtpd/2007/08/msg7144.html
> 
> And please have a look at my db/suite - where the DBI connection is
> stored in $qp->connection->notes()
> 
> On
> http://dienstleistung-kultur.de/qpsmtpd/db_common.shtml#inheritance
> you'll find a skeleton for an own plugin inheriting from db/common,
> which provides all the database handling stuff.
> 
> Just say in /etc/qpsmtpd/plugins
> 
>     db/base
>     db/your_plugin
> 
> and in db/your_plugin you can easily access your database defined in
> /etc/qpsmtpd/db_base via the methods provided by db/common.
> 
> db/suite runs on our server in production on QPSMTPD forkserver 0.32 in
> combination with Exim 4.63, MySQL 5.0.32 and Dovecot 1.0rc15 on Debian
> Etch - never change a running system ;-)
> 
> Please see http://dienstleistung-kultur.de/qpsmtpd/
> 
> Sincerely,
> Ernesto
> 

Reply via email to