8

I want to understand what's going on with this Exim configuration directory.

In /etc/exim4, there's:

* exim4.conf.template
* update-exim4.conf.conf
* conf.d

The conf.d has a mess of directories and files, and inside each are a bunch of if statements which I find really different.

For example:

maildir_home:
  debug_print = "T: maildir_home for $local_part@$domain"
  driver = appendfile
  .ifdef MAILDIR_HOME_MAILDIR_LOCATION
  directory = MAILDIR_HOME_MAILDIR_LOCATION
  .else
  directory = $home/Maildir
  .endif
  .ifdef MAILDIR_HOME_CREATE_DIRECTORY
  create_directory
  .endif
  .ifdef MAILDIR_HOME_CREATE_FILE

My question is,

-where do the CAPS VARIABLES get defined?

  • how can I change them?
  • why are there so many if statements in these configuration files?

3 Answers 3

4

This is Debian/Ubuntu's way of managing Exim4. You'll need to limit yourself to using the dpkg-reconfigure exim4-config utility and it's config file, update-exim4.conf.conf to manage it, or, just blow it all away and manage it all yourself. Check out:

http://pkg-exim4.alioth.debian.org/README/README.Debian.html#completely-different-configuration

2
  • 1
    Using a completely different configuration is not advised. It can break on updates and packages that automatically add stuff to the conf.d directory to configure exim will not work.
    – coredump
    Aug 21, 2010 at 13:33
  • 2
    This is mostly FUD. Exim has very strong backwards compatibility for configurations and won't break on updates. You only lose the automated support for other packages to insert mail-handling. You gain a configuration which doesn't have a pre-processor and config files used for building a config file. General statements "X is not advised" should be perhaps be reserved for where there is little disagreement.
    – Phil P
    Sep 1, 2010 at 2:36
10

Here's the easy guide to understand Debian's exim config:

  1. conf.d has the configuration snippets, separated by config area. The variables in caps are normally defined on the first part (called base, if my memory serves me).
  2. the exim4.conf.template is generated by concatenating all the snippets at install time, so the basic configuration is the same.
  3. the config file used by the daemon is created on a different directory based on one of the above templates.
  4. Each time you use update-exim4.conf it generates a new config file, based on what you answered when the package configuration asked about split configuration.

If you use the split configuration, you have to use files at conf.d to manage exim, otherwise use the exim4.conf.template.

I suggest you use the conf.d scheme, after you get used to it its easier to manage and add/remove stuff. Read all the files in all dirs and compare it to the running config file (/var/lib/exim4/config.autogenerated but comments are striped so re-run update-exim4.conf --keepcomments, or you can use exim -bP to see the running config too) and you will get it real easy.

Most of the times you will not need any special configuration, so just use dpkg-reconfigureexim4-config` and answer the questions.

1

Those are not really exim configuration files those are part of the debian configuration system that is used to generate the actually exim configuration file.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .