[BlueOnyx:12599] Dovecot dies with anvil too many open files

David Thacker David at ThackerNet.com
Fri Mar 22 08:38:11 -05 2013


Greetings all,

I have a recurring problem where Dovecot chokes under heavy load (login 
break-in attempts) and has to be manually restarted. The problem used to 
happen once or twice a month, but lately happens at least once a day and 
is now a reliability problem for my hosting clients.

I do have the Security > Login Manager > Host rule set to 30/h but it 
doesn't solve it.

I will get an Active Monitor texted to my phone within 15 minutes of 
Dovecot choking, but if it happens overnight it can be several hours 
before I notice and can correct it.

The problem reported in the mail logs is this:

    Error: net_connect_unix(anvil) failed: Too many open files

which is exactly as this poster described on the Dovecot mailing list 
here:

    http://dovecot.org/list/dovecot/2012-October/069070.html

A response to that post offered this suggested solution:

    http://dovecot.org/list/dovecot/2012-October/069111.html

which was to increase the max open files allowed for the Dovecot process.

On my system when I "cat /proc/<pid of anvil process>/limits" I get:

    Max open files            4096                 4096 
files

So, I stopped & killalled Dovecot, then did "ulimit -n 8192" and then 
"service dovecot restart", and when I check again, I still see max open 
files 4096 instead of 8192.


1. Can anyone help me figure out how to increase the max open files that 
Dovecot anvil has to work with, to see if this will solve the heavy-usage 
choking problem?

or

2. Can anyone suggest a way that the Active Monitor script that recognizes 
that "The POP server is not running and could not be restarted" could be 
modified to actually restart Dovecot on its own so I don't have to do it 
manually?


Regards,

dAvid tHacker                                  Email: David at ThackerNet.com
Thacker Network Technologies Inc.                http://www.ThackerNet.com




More information about the Blueonyx mailing list