MariaDB database for users and passwords?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
15 messages Options
Reply | Threaded
Open this post in threaded view
|

MariaDB database for users and passwords?

Dovecot mailing list
Greetings, All!

I've got an email server set up with Postfix and Dovecot, but Dovecot
can't find any users.  I'd ilke to use the database I set up in MariaDB
for users (referenced by Postfix), but I'm just not sure how to do it. 
There's a line in dovecot.conf specifying /etc/dovecot/passwd.db, but
obviously that's not the one I set up in MariaDB.  Is what I want even
possible?

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
Am Mittwoch, den 06.11.2019, 22:23 -0500 schrieb Ken Wright via
dovecot:

> Greetings, All!
>
> I've got an email server set up with Postfix and Dovecot, but Dovecot
> can't find any users.  I'd ilke to use the database I set up in
> MariaDB
> for users (referenced by Postfix), but I'm just not sure how to do
> it.
> There's a line in dovecot.conf specifying /etc/dovecot/passwd.db, but
> obviously that's not the one I set up in MariaDB.  Is what I want
> even
> possible?

What distribution and version of Dovecot to do you use?
I don't myself use the SQL support of it.
But on Debian there's /etc/dovecot/dovecot-sql.conf.ext to configure
it.
You can find the docs about the SQL passdb/userdb support here:

https://doc.dovecot.org/configuration_manual/authentication/sql/#authentication-sql

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
On 11/7/19 2:11 AM, Felix Zielcke via dovecot wrote:

> Am Mittwoch, den 06.11.2019, 22:23 -0500 schrieb Ken Wright via
> dovecot:
>> Greetings, All!
>>
>> I've got an email server set up with Postfix and Dovecot, but Dovecot
>> can't find any users.  I'd ilke to use the database I set up in
>> MariaDB for users (referenced by Postfix), but I'm just not sure how
>> to do it. There's a line in dovecot.conf specifying
>> /etc/dovecot/passwd.db, but obviously that's not the one I set up in
>> MariaDB.  Is what I want even possible?
> What distribution and version of Dovecot to do you use?
> I don't myself use the SQL support of it.
> But on Debian there's /etc/dovecot/dovecot-sql.conf.ext to configure
> it.
> You can find the docs about the SQL passdb/userdb support here:
>
> https://doc.dovecot.org/configuration_manual/authentication/sql/#authentication-sql

I should have included that information the first time; forgive me for
being negligent.  I'm using Ubuntu Server 18.04 LTS, and Dovecot is
version 2.2.33.2.  I'll take a look at the link you provided.  Thanks!

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list

On 11/7/19 3:26 AM, Ken Wright via dovecot wrote:

> On 11/7/19 2:11 AM, Felix Zielcke via dovecot wrote:
>> Am Mittwoch, den 06.11.2019, 22:23 -0500 schrieb Ken Wright via
>> dovecot:
>>> Greetings, All!
>>>
>>> I've got an email server set up with Postfix and Dovecot, but Dovecot
>>> can't find any users.  I'd ilke to use the database I set up in
>>> MariaDB for users (referenced by Postfix), but I'm just not sure how
>>> to do it. There's a line in dovecot.conf specifying
>>> /etc/dovecot/passwd.db, but obviously that's not the one I set up in
>>> MariaDB.  Is what I want even possible?
>> What distribution and version of Dovecot to do you use?
>> I don't myself use the SQL support of it.
>> But on Debian there's /etc/dovecot/dovecot-sql.conf.ext to configure
>> it.
>> You can find the docs about the SQL passdb/userdb support here:
>>
>> https://doc.dovecot.org/configuration_manual/authentication/sql/#authentication-sql
> I should have included that information the first time; forgive me for
> being negligent.  I'm using Ubuntu Server 18.04 LTS, and Dovecot is
> version 2.2.33.2.  I'll take a look at the link you provided.  Thanks!

I'm getting an error message saying "user unknown" when I send test
emails to my server.  I'd bet folding money the reason is Dovecot isn't
finding the MariaDB database that holds the email users, addresses,
passwords, and aliases.  Can someone help me figure this out?  I can
share the conf files and database particulars if necessary.

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
On 07 Nov 2019, at 23:00, Ken Wright <[hidden email]> wrote:
> I'm getting an error message saying "user unknown" when I send test
> emails to my server.

You need to look at the logs.



--
Everybody wants a rock to wrap a piece of string around

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
On 11/8/19 1:05 PM, @lbutlr via dovecot wrote:
> On 07 Nov 2019, at 23:00, Ken Wright <[hidden email]> wrote:
>> I'm getting an error message saying "user unknown" when I send test
>> emails to my server.
> You need to look at the logs.

Here's what I see:

***

root@grace:/etc/postfix# tail /var/log/mail.log
Nov  8 13:28:09 grace postfix/smtpd[5382]: connect from
grace.koalatyworks.com[127.0.0.1]
Nov  8 13:28:09 grace postfix/smtpd[5382]: disconnect from
grace.koalatyworks.com[127.0.0.1] ehlo=1 quit=1 commands=2
Nov  8 13:28:09 grace dovecot: imap-login: Disconnected (disconnected
before auth was ready, waited 0 secs): user=<>, rip=127.0.0.1,
lip=127.0.0.1, TLS handshaking: SSL_accept() syscall failed: Success,
session=<PE2g8dmWyr1/AAAB>
Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver 'mysql'
Nov  8 13:28:53 grace dovecot: master: Error: service(auth): command
startup failed, throttling for 60 secs
Nov  8 13:30:09 grace postfix/smtpd[6553]: connect from
grace.koalatyworks.com[127.0.0.1]
Nov  8 13:30:09 grace postfix/smtpd[6553]: disconnect from
grace.koalatyworks.com[127.0.0.1] ehlo=1 quit=1 commands=2
Nov  8 13:30:09 grace dovecot: imap-login: Disconnected (disconnected
before auth was ready, waited 0 secs): user=<>, rip=127.0.0.1,
lip=127.0.0.1, TLS handshaking: SSL_accept() syscall failed: Success,
session=<EVbI+NmW0L1/AAAB>
Nov  8 13:30:09 grace dovecot: auth: Fatal: Unknown passdb driver 'mysql'
Nov  8 13:30:09 grace dovecot: master: Error: service(auth): command
startup failed, throttling for 60 secs
***

And here's the output from dovecot -n:

***

# 2.2.33.2 (d6601f4ec): /etc/dovecot/dovecot.conf
# Pigeonhole version 0.4.21 (92477967)
# OS: Linux 4.15.0-66-generic x86_64 Ubuntu 18.04.3 LTS ext4
auth_mechanisms = plain login
auth_verbose = yes
mail_home = /var/mail/vhosts/%d/%n
mail_location = maildir:/var/mail/vhosts/%d/%n/
mail_privileged_group = mail
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope
encoded-character vacation subaddress comparator-i;ascii-numeric
relational regex imap4flags copy include variables body enotify
environment mailbox date index ihave duplicate mime foreverypart extracttext
namespace inbox {
  inbox = yes
  location =
  mailbox Drafts {
    special_use = \Drafts
  }
  mailbox Junk {
    special_use = \Junk
  }
  mailbox Sent {
    special_use = \Sent
  }
  mailbox Trash {
    special_use = \Trash
  }
  prefix =
}
passdb {
  args = username_format=%u scheme=SSHA512
  driver = mysql
}
passdb {
  args = /etc/dovecot/dovecot-sql.conf.ext
  driver = sql
}
passdb {
  args = /etc/dovecot/dovecot-sql.conf.ext
  driver = sql
}
plugin {
  sieve = file:~/sieve;active=~/.dovecot.sieve
  sieve_after = /var/mail/vmail/sieve-after
  sieve_before = /var/mail/vmail/sieve-before
  sieve_dir = ~/sieve
}
postmaster_address = [hidden email]
protocols = imap lmtp sieve
service auth-worker {
  user = vmail
}
service auth {
  unix_listener /var/spool/postfix/private/auth {
    group = postfix
    mode = 0660
    user = postfix
  }
  unix_listener /var/spool/postfix/private/dovecot-auth {
    group = postfix
    mode = 0660
    user = postfix
  }
  unix_listener auth-userdb {
    mode = 0600
    user = vmail
  }
  user = dovecot
}
service dict {
  unix_listener dict {
    group = vmail
    mode = 0600
    user = vmail
  }
}
service imap-login {
  inet_listener imap {
    port = 143
  }
  inet_listener imaps {
    port = 993
    ssl = yes
  }
}
service lmtp {
  unix_listener /var/spool/postfix/private/dovecot-lmtp {
    group = postfix
    mode = 0600
    user = postfix
  }
}
ssl = required
ssl_cert = </etc/letsencrypt/live/koalatyworks.com/fullchain.pem
ssl_cipher_list =
ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AES:RSA+3DES:ADH:!AECDH:!MD5:!DSS
ssl_client_ca_dir = /etc/ssl/certs
ssl_key =  # hidden, use -P to show it
userdb {
  args = uid=5000 gid=5000 home=/var/mail/vhosts/%d/%n
  driver = mysql
}
userdb {
  args = uid=5000 gid=5000 home=/var/mail/vhosts/%d/%n
  driver = static
}
protocol imap {
  imap_client_workarounds = delay-newmail tb-extra-mailbox-sep
  mail_max_userip_connections = 10
}
protocol lda {
  deliver_log_format = msgid=%m: %$
  mail_plugins = sieve
  quota_full_tempfail = yes
  rejection_reason = Your message to <%t> was automatically rejected:%n%r
}
protocol lmtp {
  mail_plugins = sieve
  postmaster_address = [hidden email]
}
***

I hope someone can explain to me just what protocol I should be using to
access a MariaDB database.

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
>>>>> "Ken" == Ken Wright via dovecot <[hidden email]> writes:

Ken> On 11/8/19 1:05 PM, @lbutlr via dovecot wrote:
>> On 07 Nov 2019, at 23:00, Ken Wright <[hidden email]> wrote:
>>> I'm getting an error message saying "user unknown" when I send test
>>> emails to my server.
>> You need to look at the logs.

Ken> Here's what I see:

Ken> ***

Ken> root@grace:/etc/postfix# tail /var/log/mail.log
Ken> Nov  8 13:28:09 grace postfix/smtpd[5382]: connect from
Ken> grace.koalatyworks.com[127.0.0.1]
Ken> Nov  8 13:28:09 grace postfix/smtpd[5382]: disconnect from
Ken> grace.koalatyworks.com[127.0.0.1] ehlo=1 quit=1 commands=2
Ken> Nov  8 13:28:09 grace dovecot: imap-login: Disconnected (disconnected
Ken> before auth was ready, waited 0 secs): user=<>, rip=127.0.0.1,
Ken> lip=127.0.0.1, TLS handshaking: SSL_accept() syscall failed: Success,
Ken> session=<PE2g8dmWyr1/AAAB>
Ken> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver 'mysql'

This line right here looks to be the problem.  Do you have mysql
support compiled into your Dovecot instance?  I run my own domain and
I thought I'd do SQL (mysql or sqllite) for my stuff, but the
compilications were so much that it was simpler to drop to plain text
files.

IMHO, if you have less than 500 users, just got flat files to start.

But back to your case, did you install the 'dovecot-mysql' package
with your distribution?  For debian, I search with:

     apt-cache search dovecot | grep mys

For redhat you could do:

    yum search dovecot

and see if you need to install it.


Ken> And here's the output from dovecot -n:

Ken> ***

Ken> # 2.2.33.2 (d6601f4ec): /etc/dovecot/dovecot.conf
Ken> # Pigeonhole version 0.4.21 (92477967)
Ken> # OS: Linux 4.15.0-66-generic x86_64 Ubuntu 18.04.3 LTS ext4
Ken> auth_mechanisms = plain login
Ken> auth_verbose = yes
Ken> mail_home = /var/mail/vhosts/%d/%n
Ken> mail_location = maildir:/var/mail/vhosts/%d/%n/
Ken> mail_privileged_group = mail
Ken> managesieve_notify_capability = mailto
Ken> managesieve_sieve_capability = fileinto reject envelope
Ken> encoded-character vacation subaddress comparator-i;ascii-numeric
Ken> relational regex imap4flags copy include variables body enotify
Ken> environment mailbox date index ihave duplicate mime foreverypart extracttext
Ken> namespace inbox {
Ken>   inbox = yes
Ken>   location =
Ken>   mailbox Drafts {
Ken>     special_use = \Drafts
Ken>   }
Ken>   mailbox Junk {
Ken>     special_use = \Junk
Ken>   }
Ken>   mailbox Sent {
Ken>     special_use = \Sent
Ken>   }
Ken>   mailbox Trash {
Ken>     special_use = \Trash
Ken>   }
Ken>   prefix =
Ken> }
Ken> passdb {
Ken>   args = username_format=%u scheme=SSHA512
Ken>   driver = mysql
Ken> }
Ken> passdb {
Ken>   args = /etc/dovecot/dovecot-sql.conf.ext
Ken>   driver = sql
Ken> }
Ken> passdb {
Ken>   args = /etc/dovecot/dovecot-sql.conf.ext
Ken>   driver = sql
Ken> }
Ken> plugin {
Ken>   sieve = file:~/sieve;active=~/.dovecot.sieve
Ken>   sieve_after = /var/mail/vmail/sieve-after
Ken>   sieve_before = /var/mail/vmail/sieve-before
Ken>   sieve_dir = ~/sieve
Ken> }
Ken> postmaster_address = [hidden email]
Ken> protocols = imap lmtp sieve
Ken> service auth-worker {
Ken>   user = vmail
Ken> }
Ken> service auth {
Ken>   unix_listener /var/spool/postfix/private/auth {
Ken>     group = postfix
Ken>     mode = 0660
Ken>     user = postfix
Ken>   }
Ken>   unix_listener /var/spool/postfix/private/dovecot-auth {
Ken>     group = postfix
Ken>     mode = 0660
Ken>     user = postfix
Ken>   }
Ken>   unix_listener auth-userdb {
Ken>     mode = 0600
Ken>     user = vmail
Ken>   }
Ken>   user = dovecot
Ken> }
Ken> service dict {
Ken>   unix_listener dict {
Ken>     group = vmail
Ken>     mode = 0600
Ken>     user = vmail
Ken>   }
Ken> }
Ken> service imap-login {
Ken>   inet_listener imap {
Ken>     port = 143
Ken>   }
Ken>   inet_listener imaps {
Ken>     port = 993
Ken>     ssl = yes
Ken>   }
Ken> }
Ken> service lmtp {
Ken>   unix_listener /var/spool/postfix/private/dovecot-lmtp {
Ken>     group = postfix
Ken>     mode = 0600
Ken>     user = postfix
Ken>   }
Ken> }
Ken> ssl = required
Ken> ssl_cert = </etc/letsencrypt/live/koalatyworks.com/fullchain.pem
Ken> ssl_cipher_list =
Ken> ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AES:RSA+3DES:ADH:!AECDH:!MD5:!DSS
Ken> ssl_client_ca_dir = /etc/ssl/certs
Ken> ssl_key =  # hidden, use -P to show it
Ken> userdb {
Ken>   args = uid=5000 gid=5000 home=/var/mail/vhosts/%d/%n
Ken>   driver = mysql
Ken> }
Ken> userdb {
Ken>   args = uid=5000 gid=5000 home=/var/mail/vhosts/%d/%n
Ken>   driver = static
Ken> }
Ken> protocol imap {
Ken>   imap_client_workarounds = delay-newmail tb-extra-mailbox-sep
Ken>   mail_max_userip_connections = 10
Ken> }
Ken> protocol lda {
Ken>   deliver_log_format = msgid=%m: %$
Ken>   mail_plugins = sieve
Ken>   quota_full_tempfail = yes
Ken>   rejection_reason = Your message to <%t> was automatically rejected:%n%r
Ken> }
Ken> protocol lmtp {
Ken>   mail_plugins = sieve
Ken>   postmaster_address = [hidden email]
Ken> }
Ken> ***

Ken> I hope someone can explain to me just what protocol I should be using to
Ken> access a MariaDB database.

Ken> Ken

Ken> --
Ken> Registered Linux user #483005

Ken> If you ever think international relations make sense, remember this:  
Ken> because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
In reply to this post by Dovecot mailing list
On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘

You do not have Dovecot compiled with support for mysql'




--
Love is like oxygen / You get too much / you get too high / Not enough
and you're gonna die

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
In reply to this post by Dovecot mailing list
On 11/8/19 2:52 PM, John Stoffel via dovecot wrote:

>>>>>> "Ken" == Ken Wright via dovecot <[hidden email]> writes:
>>>>>>
>>>>>> Ken> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver 'mysql'
>>>>>>
>>>>>> This line right here looks to be the problem.  Do you have mysql
>>>>>> support compiled into your Dovecot instance?  I run my own domain and
>>>>>> I thought I'd do SQL (mysql or sqllite) for my stuff, but the
>>>>>> compilications were so much that it was simpler to drop to plain text
>>>>>> files.
>>>>>>
>>>>>> IMHO, if you have less than 500 users, just got flat files to start.
>>>>>>
>>>>>> But back to your case, did you install the 'dovecot-mysql' package
>>>>>> with your distribution?  For debian, I search with:
>>>>>>
>>>>>>      apt-cache search dovecot | grep mys
>>>>>>
Okay, I checked, and dovecot-mysql is installed.  I can't see why that
driver is unknown!

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
In reply to this post by Dovecot mailing list

On 11/8/19 3:14 PM, @lbutlr via dovecot wrote:
> On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
>> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘
> You do not have Dovecot compiled with support for mysql'
>
But the dovecot-mysql package is installed!  Why can't it see that?

Ken

--

Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
Am 08.11.2019 um 21:23 schrieb Ken Wright via dovecot:
>
> On 11/8/19 3:14 PM, @lbutlr via dovecot wrote:
>> On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
>>> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘
>> You do not have Dovecot compiled with support for mysql'
>>
> But the dovecot-mysql package is installed!  Why can't it see that?
>
> Ken

The driver is called "sql". See

https://doc.dovecot.org/configuration_manual/authentication/sql/

Alexander


Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list

On 11/8/19 3:40 PM, Alexander Dalloz via dovecot wrote:

> Am 08.11.2019 um 21:23 schrieb Ken Wright via dovecot:
>>
>> On 11/8/19 3:14 PM, @lbutlr via dovecot wrote:
>>> On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
>>>> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘
>>> You do not have Dovecot compiled with support for mysql'
>>>
>> But the dovecot-mysql package is installed!  Why can't it see that?
>>
>
> The driver is called "sql". See
>
> https://doc.dovecot.org/configuration_manual/authentication/sql/
>
> Alexander
>
Are you sure?  I looked at that page, and it says there are different
drivers for MySQL and PostgreSQL:  mysql and pgsql respectively.  I also
checked dovecot.conf, and there the driver is called "sql."

Ken

--
Registered Linux user #483005

If you ever think international relations make sense, remember this:  
because a Serb shot an Austrian in Bosnia, Germany invaded Belgium.

Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list

> On 09/11/2019 05:44 Ken Wright via dovecot <[hidden email]> wrote:
>
>  
> On 11/8/19 3:40 PM, Alexander Dalloz via dovecot wrote:
> > Am 08.11.2019 um 21:23 schrieb Ken Wright via dovecot:
> >>
> >> On 11/8/19 3:14 PM, @lbutlr via dovecot wrote:
> >>> On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
> >>>> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘
> >>> You do not have Dovecot compiled with support for mysql'
> >>>
> >> But the dovecot-mysql package is installed!  Why can't it see that?
> >>
> >
> > The driver is called "sql". See
> >
> > https://doc.dovecot.org/configuration_manual/authentication/sql/
> >
> > Alexander
> >
> Are you sure?  I looked at that page, and it says there are different
> drivers for MySQL and PostgreSQL:  mysql and pgsql respectively.  I also
> checked dovecot.conf, and there the driver is called "sql."
>
> Ken

SQL is the **authentication** database, which has mysql **driver**. So in dovecot.conf you use sql, and in the config file for the sql authentication, you specify the driver. See https://github.com/dovecot/core/blob/master/doc/example-config/dovecot-sql.conf.ext#L32

Aki
Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
In reply to this post by Dovecot mailing list
Ken Wright via dovecot skrev den 2019-11-09 04:44:

> Are you sure?  I looked at that page, and it says there are different
> drivers for MySQL and PostgreSQL:  mysql and pgsql respectively.  I
> also
> checked dovecot.conf, and there the driver is called "sql."

docecot maps files have the driver line, not doveconf config

https://doc.dovecot.org/configuration_manual/authentication/sql/#postgresql

imho confusing comes from dovecot conf that its not very obevoius when
to use sql in doveconf -n output
Reply | Threaded
Open this post in threaded view
|

Re: MariaDB database for users and passwords?

Dovecot mailing list
In reply to this post by Dovecot mailing list
There is some ambiguity in the setting names, however:

In the "upper" authentication config file (possibly
conf.d/auth-sql.conf.ext) you define which "internal" driver the
authentication system will use. These are...more of a top-level engine
selection if you will - perhaps not what you'd consider a "true" driver.

In the "lower" authentication config file (like dovecot-sql.conf.ext),
which is referenced by the 'args' setting in the userdb & passdb
sections of the "upper" file, is where you explicitly specific the
"true" driver, the actual database, and any field mappings.

If you're just getting things setup I suggest you check out:

http://postfixadmin.sourceforge.net/

Very clean & simple admin GUI for mail services. It includes
documentation for setting up Dovecot.

Daniel


On 11/8/2019 11:12 PM, Aki Tuomi via dovecot wrote:

>
>> On 09/11/2019 05:44 Ken Wright via dovecot <[hidden email]> wrote:
>>
>>  
>> On 11/8/19 3:40 PM, Alexander Dalloz via dovecot wrote:
>>> Am 08.11.2019 um 21:23 schrieb Ken Wright via dovecot:
>>>>
>>>> On 11/8/19 3:14 PM, @lbutlr via dovecot wrote:
>>>>> On 08 Nov 2019, at 11:56, Ken Wright <[hidden email]> wrote:
>>>>>> Nov  8 13:28:53 grace dovecot: auth: Fatal: Unknown passdb driver ‘
>>>>> You do not have Dovecot compiled with support for mysql'
>>>>>
>>>> But the dovecot-mysql package is installed!  Why can't it see that?
>>>>
>>>
>>> The driver is called "sql". See
>>>
>>> https://doc.dovecot.org/configuration_manual/authentication/sql/
>>>
>>> Alexander
>>>
>> Are you sure?  I looked at that page, and it says there are different
>> drivers for MySQL and PostgreSQL:  mysql and pgsql respectively.  I also
>> checked dovecot.conf, and there the driver is called "sql."
>>
>> Ken
>
> SQL is the **authentication** database, which has mysql **driver**. So in dovecot.conf you use sql, and in the config file for the sql authentication, you specify the driver. See https://github.com/dovecot/core/blob/master/doc/example-config/dovecot-sql.conf.ext#L32
>
> Aki
>