[no subject]

2018-08-17 Thread Jarrad
Unsubscribe

[Dovecot] Dovecot IMAPS and slow reconnections

2013-04-16 Thread Jarrad

Hi List,

I've recently moved from postfix + courier-imap to a new server with 
postfix + dovecot with a mysql user management.


I have it up and running and receiving mail ok but I'm having problems 
with IMAP connections being slow. I have an iphone with multiple imap 
accounts set up on it (4 I think) and when I open the mail app it 
connects to first account quickly. Then if I navigate to another account 
it takes about 1 minute to connect (sits there with the 'connecting' 
status)


Looking at the logs it shows the connection come through at the same 
time the iphone actually connects so it's as if something is timing out 
before it actually connects.


My setup is an Amazon EC2 micro instance running debian wheezy. There 
is about 5 domains being hosted with approximately 4-5 accounts for each 
so it's not a heavy load by any means. I've tried bumping up the max 
connections, service_count and minimum processes but nothing seems to 
help.


Any advice is much appreciated.

My config is as per below:

# 2.1.7: /etc/dovecot/dovecot.conf
# OS: Linux 3.2.0-4-amd64 x86_64 Debian 7.0 ext4
auth_debug = yes
auth_verbose = yes
disable_plaintext_auth = no
mail_location = maildir:/var/vmail/%d/%n/Maildir
namespace inbox {
  inbox = yes
  location =
  mailbox Drafts {
special_use = \Drafts
  }
  mailbox Junk {
special_use = \Junk
  }
  mailbox Sent {
special_use = \Sent
  }
  mailbox Sent Messages {
special_use = \Sent
  }
  mailbox Trash {
special_use = \Trash
  }
  prefix =
}
passdb {
  args = /etc/dovecot/dovecot-sql.conf.ext
  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 = vmail
mode = 0600
user = vmail
  }
}
service imap-login {
  process_min_avail = 5
  service_count = 10
}
ssl_cert = /etc/dovecot/dovecot.pem
ssl_key = /etc/dovecot/private/dovecot.key
userdb {
  args = uid=5000 gid=5000 home=/var/vmail/%d/%n/Maildir 
allow_all_users=yes

  driver = static
}
verbose_ssl = yes
protocol lda {
  auth_socket_path = /var/run/dovecot/auth-master
  log_path =
  mail_plugins =
  postmaster_address = removed for spam reasons
}
protocol imap {
  mail_max_userip_connections = 100
}