How to increase mail connections (error: refused: too many connections)?


I have many connection (send, read, etc) from one ip to different mails in my server. I get this error in my log and users cant used their mails:

Connection from [xx.xx.xx.xx] refused: too many connections

How to increase this number. I readed about smtp_accept_max, but cant find it in config files.

Thanks in advance

You can add smtp_accept_max to the existing config in /etc/exim4/exim4.conf.template, this “should” work.


As @Raphael said, editing /etc/exim4/exim4.conf.template and adding directive smtp_accept_max = HereTheNumber must work, maybe you should raise another smtp_accept limit.

If you want to check the current values used in your Exim service:

exim -bP | grep 'smtp_accept_max.*[0-9]$'

In my defauklt conf it’s like this:

# exim -bP | grep 'smtp_accept_max.*[0-9]$'
smtp_accept_max = 20
smtp_accept_max_nonmail = 10
smtp_accept_max_per_connection = 1000

I raised it, thanks for yours fast replys! Another question here - what is smtp_accept_max_nonmail used for?

The non-mail SMTP commands are those other than MAIL, RCPT, and DATA. Exim counts such commands and drops the connection if there are too many of them in a single SMTP session.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.