0

Debian/Ubuntu seem to have very complex Exim4 configuration files:

Understanding exim configuration files

What would be the recommendation if I want to raise the value of smtp_accept_max value? Is it autogenerated somewhere or is it possible to put this to a conf template and run [some script]?

Mikko Ohtamaa
  • 1,374
  • 3
  • 17
  • 28

2 Answers2

4

There is a default value hard-coded as for many settings. See the Exim4 specification document. You can install the exim4-doc package to have it installed locally.

To change this value and a number of other values you need to get it added to the main section of the configuration.

  • For a split configuration create an /etc/exim4/conf.d/main/00_local_settings file. Place your change in it.
  • For a template configuration create an /etc/exim4/exim4.conf.localmacros file. Put your changes in it.

These files are prefixed to rest of the configuration. Settings in these files can be used to override many configuration macros. Look of .ifndef wrapping the definition in the configuration files to identify these.

Reload your changes using /etc/init.d/exim4 reload. You will find the new file as /var/lib/exim4/config.autogenerated. If your configuration fails to validate, the file will be in same location with different name. (There are are most two files so it should be easy to find.

Documentation on the various Exim components can be found in /usr/share/doc/. The directories for Exim documention have names beginning exim. Man pages are available and can be found with the command man -k exim. For your case you may want to read the output of man update-exim4.conf.conf, the command that creates the running configuration from the templates.

BillThor
  • 27,737
  • 3
  • 37
  • 69
0

For the benefit of those that also end up here due to incorrect google auto search suggestions note that smtp_accept_max is not the correct setting, but message_size_limit is.

To set it you must add the MESSAGE_SIZE_LIMIT macro to your /etc/exim4/conf.d/00_exim4-localconfig-macros file (create file as needed) like so:

...
# DS,2016-Jan-15: Increasing maximum email size from default 50M
MESSAGE_SIZE_LIMIT = 100M
...

Don't forget to reload your exim by running /etc/init.d/exim4 reload.