Wednesday, January 31, 2007

Plesk and Courier IMAP

Seeing "Unable to connect to your IMAP server. You may have exceeded the maximum number of connections to this server" has been driving me insane!

Whenever I add another account to Thunderbird, I have to specify that it can only have one connection to the server per account and even then, if my wife switches on her machine, we have more than the prespecified Plesk maximum of 4 IMAP connections and we start getting errors.

I devided that enough was enough and went in search of a solution. I found it too :o)
perl -p -i -e 's/^MAXDAEMONS=40/MAXDAEMONS=80/g' /etc/courier-imap/imapd
perl -p -i -e 's/^MAXPERIP=4/MAXPERIP=40/g' /etc/courier-imap/imapd
Then a quick restart of the service and all should be working.
/etc/init.d/courier-imap stop
/etc/init.d/courier-imap start
These changes increase the maximum daemons to 80 and Maximum connections per IP to 40. Should be enought for us at the momnet, but may need altered in the future.

1 comment:

Thadeus said...

well, thanks, sounds nice.