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]?
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.
/etc/exim4/conf.d/main/00_local_settings
file. Place your change in it./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 beginningexim
. Man pages are available and can be found with the commandman -k exim
. For your case you may want to read the output ofman update-exim4.conf.conf
, the command that creates the running configuration from the templates.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, butmessage_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:Don't forget to reload your exim by running
/etc/init.d/exim4 reload
.