Dovecot config not compatible with the one in HowToForge
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Bebian Sid for server, KXStudio 12.04 Beta 1 for desktop
Posts: 33
Rep:
Dovecot config not compatible with the one in HowToForge
The article states that it's for Arch, but it should work for Debian Sid with the use of apt-get instead of pacman. Anyway, here's what I'm having trouble with.
# 2.0.18: /etc/dovecot/dovecot.conf
doveconf: Warning: NOTE: You can get a new clean config file with: doveconf -n > dovecot-new.conf
doveconf: Warning: Obsolete setting in /etc/dovecot/dovecot.conf:15: add auth_ prefix to all settings inside auth {} and remove the auth {} section completely
doveconf: Fatal: Error in configuration file /etc/dovecot/dovecot.conf line 17: Unknown setting: auth_passdb
root@debian-server:/home/grayson#
I've been looking for the howto articles long and hard trying to find anything up-to-date (like 2012) and all I've been looking for is out-of-date articles as postfix -n told me to replace ssl_cert_file with ssl_cert, ssl_key_file with ssl_key, replace this with that, add auth_ prefix to everything inside the auth{} section and remove auth{} but dovecot complains even more with warnings, and this is getting very endless.
Is dovecot obsolete? Without any up-to-date howto guide for setting up dovecot, I'm confused.
Last edited by GraysonPeddie; 04-19-2012 at 12:51 AM.
Reason: I forgot to post a link to the article that is giving me trouble.
Maybe you are using a dovecot 2.x conf instead of 1.2.x ...
That was my thought too. If you are migrating from version 1, you will get warnings about certain functions being deprecated and, or not supported along with a message about "running dovecot -n" or something to that effect. What that will do is give you a cleaned up configuration file that converts the settings to the new format.
Here is my Dovecot2 configuration. As long as I created or copied the files in the correct directories, they had the proper context for SELinux. You will need to be careful of that and if you are using SELinux check with an ls -aZ. This was "cleaned up" by the auto modification tool from a Dovecot 1 configuration.
Code:
# 2.0.14: /etc/dovecot/dovecot.conf
auth_mechanisms = plain cram-md5 digest-md5
base_dir = /var/run/dovecot/
first_valid_uid = 5000
last_valid_uid = 5000
log_timestamp = "%Y-%m-%d %H:%M:%s "
mail_location = maildir:/var/mail/%d/%n
#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
passdb {
args = /etc/dovecot/dovecot-sql.conf
driver = sql
}
protocols = imap pop3
service auth {
unix_listener /var/spool/postfix/private/auth {
group = postfix
mode = 0660
user = postfix
}
unix_listener auth-master {
group = mail
mode = 0660
user = vmail
}
#user = nobody
#Not sure about this one, it came from the Gentoo Wiki on Dovecot 2
user = root
}
service auth-worker {
# user = $default_internal_user
# remembered this from gentoo docs
user = root
unix_listener auth-worker {
user = postfix
}
}
service imap-login {
executable = /usr/libexec/dovecot/imap-login
inet_listener imap {
address = *
port = 143
}
inet_listener imaps {
address = *
port = 993
}
}
service imap {
executable = /usr/libexec/dovecot/imap
}
service pop3-login {
executable = /usr/libexec/dovecot/pop3-login
inet_listener pop3 {
address = *
port = 110
}
inet_listener pop3s {
address = *
port = 995
}
}
service pop3 {
executable = /usr/libexec/dovecot/pop3
}
ssl_cert = </etc/postfix/ssl.crt
ssl_key = </etc/postfix/ssl.key
userdb {
args = /etc/dovecot/dovecot-sql.conf
driver = sql
}
protocol imap {
imap_client_workarounds = tb-extra-mailbox-sep
imap_max_line_length = 64 k
}
protocol pop3 {
pop3_uidl_format = %08Xu%08Xv
}
protocol lda {
auth_socket_path = /var/run/dovecot/auth-master
postmaster_address = postmaster@
sendmail_path = /usr/lib/sendmail
}
I would recommend, if you haven't already, turning on debugging in Dovecot. There are about 3 different debugging methods and option in dovecot. I can't recall the off hand, but I think the man and wiki pages discuss them. You should be able to get some information from your mail log, with and without the debugging too.
This is very basic so it's not going to be that secure.
Once I've restarted Dovecot, here's what I got:
Code:
root@debian-server:/home/grayson# telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE STARTTLS AUTH=PLAIN AUTH=LOGIN] Dovecot ready.
Once I've changed the two lines for dovecot.pem to graysonpeddie.crt and graysonpeddie.key, it also worked. It turns out I have to add a < for both of the lines as shown in my code. Weird.
It turns out I have to add a < for both of the lines as shown in my code.
Now that you mention this, I recall running into this problem too. I think it generated an error message in the log file upon restart and I can't recall where I saw the "fix" documented at, but I think it is one of the new features unique to Dovecot 2, that should be an FAQ.
Distribution: Bebian Sid for server, KXStudio 12.04 Beta 1 for desktop
Posts: 33
Original Poster
Rep:
Hmm... It seems to me that the ampersand have been ignored.
By the way, it would be nice if the Debian Sid repository contains Dovecot 1 and Dovecot 2, but that is what I get for running Debian Sid as I like to stay in the bleeding edge of things, like Mono 2.10 and MythTV 0.25. Otherwise, there needs to be howto articles for Dovecot 2 for those who are starting afresh and are using the latest version of their chosen distribution (like CentOS (not a rolling release) or Arch Linux).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.