Hello all.. I'm trying to configure dovecot do athenticate using mysql, but I?m having some troubles... After configuring the mysql athentication in dovecot-mysql.conf and in dovecot.conf, when I try to login I get this mesage in my logs: Dovecot-auth: MySQL: Can't connect to database dovecot: Can't connect to local MySQL server through socket '/var/tmp/mysql.sock' (2) Any ideia why this happens and how to fix it? Thanks in advance, Pedro
That means that mysqld is not running or dovecot is looking in the wrong place for it. Can you get to mysql from the command line? If so, you'll need to figure out where mysql.sock is located (look in / etc/my.cnf) and then point dovecot to it. If you can't run mysql from the command line then the daemon is not running and you will need to start it. - Jon On Apr 26, 2006, at 4:01 PM, Pedro Vieira wrote:> Hello all.. > > > I'm trying to configure dovecot do athenticate using mysql, but I?m > having some troubles... > After configuring the mysql athentication in dovecot-mysql.conf and > in dovecot.conf, when I try to login I get this mesage in my logs: > > Dovecot-auth: MySQL: Can't connect to database dovecot: Can't > connect to local MySQL server through socket '/var/tmp/mysql.sock' (2) > > > > Any ideia why this happens and how to fix it? > > > Thanks in advance, > > > Pedro-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://dovecot.org/pipermail/dovecot/attachments/20060426/77205bd2/attachment.html>
Problem solved.... that "d" that was missing was the source of all my problems. Thank you all for your help! :) Pedro Jon Baker wrote:> Can you see a file located at /var/run/mysqld/mysql.sock? > > What is the contents of my.cnf? > > On Apr 27, 2006, at 6:56 PM, Pedro Vieira wrote: > >> I have mysql running and I can log in from command line, make queries >> both from command line and external software (apache+php)... >> >> Jon Baker wrote: >>> What happens if you type mysql at the command line? >>> >>> On Apr 27, 2006, at 6:42 PM, Pedro Vieira wrote: >>> >>>> Already did it... now i have this error: >>>> >>>> dovecot-auth: MySQL: Can't connect to database dovecot: Can't >>>> connect to local MySQL server through socket >>>> '/var/run/mysqld/mysql.sock' (2) >>>> >>>> >>>> I already have smoke comming out of my head.... :S >>>> >>>> Jon Baker wrote: >>>>> Um... uncomment your socket line perhaps? >>>>> >>>>> On Apr 27, 2006, at 5:46 PM, Pedro Vieira wrote: >>>>> >>>>>> db_host = localhost >>>>>> db_port = 3306 >>>>>> #db_unix_socket = /var/run/mysqld/mysql.sock >>>>>> db = mydovecotdb >>>>>> db_user = mydovecotuser >>>>>> db_passwd = mydbpasswd >>>>>> db_client_flags = 0 >>>>> >>>> >>> >>> >> > >