[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.
Action disabled: register

Welcome to the Slackware Documentation Project

I have changed Dovecot's mysql connection string. The former was:

host=localhost dbname=mailserver user=mailuser pass={your mailuser password}

This produces the following error at /var/log/maillog:

Apr  1 17:54:23 darkstar dovecot: auth: Fatal: mysql: Unknown connect string: pass

The comments in /etc/dovecot/dovecot-sql.conf.ext clearly states:

# Database connection string. This is driver-specific setting.
...
# mysql:
#   Basic options emulate PostgreSQL option names:
#     host, port, user, password, dbname

This is also confirmed by Dovecot's documentation:

# The mysqld.sock socket may be in different locations in different systems.
# Use "host= ... pass=foo#bar" with double-quotes if your password has '#' character.
connect = host=/var/run/mysqld/mysqld.sock dbname=mails user=admin password=pass
# Alternatively you can connect to localhost as well:
#connect = host=localhost dbname=mails user=admin password=pass

I have also followed the advice on double quotes for special characters in the password.

So, the new connection string is:

"host=localhost dbname=mailserver user=mailuser password={your mailuser password}"

This change refers to Dovecot v2.2.13.

By the way, I would like to thanks astrogeek for this article. It's quite precise and clear!

Deny Dias 2015/04/01 18:36

 talk:howtos:network_services:postfix_dovecot_mysql:dovecot ()