Q0601

Nigel Metheringham edited this page Nov 29, 2012 · 2 revisions
Clone this wiki locally

Q0601

Question

What does the error Neither the xxx router nor the yyy transport set a uid for local delivery of... mean?

Answer

Whenever Exim does a local delivery, it runs a process under a specific user and group id (uid and gid). For deliveries into mailboxes, and to pipes and files set up by forwarding, it normally picks up the uid/gid of the receiving user. However, if an address is directed to a pipe or a file by some other means, such an entry in the system alias file of the form

majordomo: |/local/mail/majordomo ...

then Exim has to be told what uid/gid to use for the delivery. This can be done either on the routerr that handles the address, or on the transport that actually does the delivery. If a pipe is going to run a setuid program, then it doesn't matter what uid Exim starts it out with, and so the most straightforward thing is to put

user = exim

on either the router or the transport. A setting on the transport overrides a setting on the router, so if the same transport is being used with several routers, you should set the user on it only if you want the same uid to be used in all cases. In the default configuration, the transports used for file and pipe deliveries are the ones called address_file and address_pipe. You can specify different transports by setting, for example,

pipe_transport = special_pipe_transport

on the system_aliases router. Then you can set up special_pipe_transport

special_pipe_transport:
  driver = pipe
  user = ????

which will be used only for pipe deliveries from that one router. What you put for the ???? is up to you, and depends on the particular circumstances.