Dovecot

---Dovecot Error-----

service dovecot status or systemctl status dovecot

# chown root:dovecot /var/run/dovecot

Dove code Check

# doveconf -n

#  doveconf -h

[root@mail ~]# dovecot -F

Fatal: Dovecot is already running with PID 7833 (read from /var/run/dovecot/master.pid)

rm -f /var/run/dovecot/master.pid systemctl status dovecot ps aux | grep -v grep | grep dovecot

[root@mail dovecot]# grep -ir idle *

conf.d/10-mail.conf:# When IDLE command is running, mailbox is checked once in a while to see if

conf.d/10-mail.conf:#mailbox_idle_check_interval = 30 secs

conf.d/20-imap.conf:  # IDLEing.

conf.d/20-imap.conf:  #imap_idle_notify_interval = 2 mins

Dovecote ISSUE

Starting Dovecot Imap: Error: service(pop3-login): listen(*, 110) failed: Address already in use Error: service(pop3-login): listen(*, 995) failed: Address already in use Error: service(imap-login): listen(*, 143) failed: Address already in use Error: service(imap-login): listen(*, 993) failed: Address already in use Fatal: Failed to start listeners                                                            [FAILED]

#yum remove psa-courier-imap

#kill dovecot

#killall -9 dovecot kills them all

solved core dump dovecot

if use redhat/fedora/centos just only run those command with root privileges

#/etc/init.d/dovecot stop

#echo 'DAEMON_COREFILE_LIMIT="unlimited"' >> /etc/sysconfig/dovecot

#/etc/init.d/dovecot start

*******

Mar 24 09:06:05 mail dovecot: imap(habib1@worldcm.net): Fatal: master: service(imap): child 4736 returned error 83 (Out of memory (service imap { vsz_limit=256 MB }, you may need to increase it) - set CORE_OUTOFMEM=1 environment to get core dump)

vi /etc/dovecot/conf.d/10-master.conf

7  # default_vsz_limit = 256M 

     default_vsz_limit = 1024M 

increasing vsz_limit



service imap{} was not present in the dovecot.conf.

I've created the service and added "vsz_limit="..

service imap {

  vsz_limit = 1024MB

}

No errors after that and mails are loading now..

thanks..

[root@mail1 ~]# vim /etc/dovecot/conf.d/20-managesieve.conf 

#uncomment to enable managesieve protocol protocols = $protocols sieve service managesieve-login{    inet_listener sieve{    port = 4190 } service_count = 1 process_min_avail = 0 vsz_limit = 1024M }

--Dovecot-----Show username for "SASL LOGIN authentication failed: UGFzc3dvcmQ6-----------------

#  vi /etc/dovecot/conf.d/10-logging.conf

auth_verbose = yes

mail_debug = yes

                               ---x----

 the dovecot.conf file (should be /etc/dovecot/dovecot.conf) and add these two lines to enable verbose logging:

auth_verbose = yes

mail_debug = yes

then restart dovecot. If you get too much verbose output, then just try auth_verbose only. SASL LOGIN authentication failed != hacked

 it is useful to show user name. As we can know which email account are in high risk and let me to do more step to prevent hacker try to hack password 

              --------------------X-----------------------

vi /etc/dovecot/conf.d/10-auth.conf

In part 2, we used the following value for auth_username_format.

auth_username_format = %n

The %n would drop away the domain if it was given. Because in part 2 we were using local Unix account for the username of every email address, we must use %n to drop away the domain, so users were able to login with the full email address.

Now we are using virtual mailbox domains, which means the username of every email address includes the domain part, so we need to change the auth_username_format as follows. %u won’t drop away the domain. This allows users to login with the full email address.

auth_username_format = %u

Uncomment the following line at the end of the file, so Dovecot can query user information from the database.

!include auth-sql.conf.ext

It can be helpful to add the following two lines in this file to debug login issues. The login errors would be logged into /var/log/maillog file. (Once users can login without problems, you can comment out the following two lines.)

auth_debug = yes auth_debug_passwords = yes

---