On Tue, 14 Jan 2003, BenEBoy wrote:
I'm about two steps from abandoning my SuSE linux install to my whizzy linuxfromscratch setup but I've hit a dead end. Exim just won't deliver mail properly...
Everytime it gets mail it moans about not being able to get a lock on /var/mail/<whatever> (where I *plan* to store my messages), because of the 'permissions' and defers them. When installing exim I set up an 'exim' user and group and chown/chgrp 'ed /var/mail to that user (and the subdirectories) and in a fit of desparation did a chmod 666 without any success (that is the chmod worked but exim still didn't ::grin::)
So....arrrggghhh! I've tried disabling locking altogether with no luck and I'm desperate. Can anyone help me pretty please?
Cheers,
BenE
I've had this problem before... very easy to fix
See the text below from the Exim website (www.exim.org)
HTH
Chris
Q0036: Why do I get the error Permission denied: creating lock file hitching post when Exim tries to do a local delivery?
A0036: Your configuration specifies that local mailboxes are all held in single directory, via configuration lines like these (taken from the default configuration):
local_delivery: driver = appendfile file = /var/mail/$local_part and the permissions on the directory probably look like this:
drwxrwxr-x 3 root mail 512 Jul 9 13:48 /var/mail/ Using the default configuration, Exim runs as the local user when doing a local delivery, and it uses a lock file to prevent any other process from updating the mailbox while it is writing to it. With those permissions the delivery process, running as the user, is unable to create a lock file in the (/var/mail( directory. There are two solutions to this problem:
(1) Set the write and sticky bit permissions on the directory, so that it looks like this:
drwxrwxrwt 3 root mail 512 Jul 9 13:48 /var/mail/ The w allows any user to create new files in the directory, but the t bit means that only the creator of a file is able to remove it. This is the same setting as is normally used with the /tmp directory.
(2) Arrange to run the local_delivery transport under a specific group by changing the configuration to read
local_delivery: driver = appendfile file = /var/mail/${local_part} group = mail The delivery process still runs under the user's uid, but with the group set to mail. The group permission on the directory allows the process to create and remove the lock file.
The choice between (1) and (2) is up to the administrator. If the second solution is used, users can empty their mailboxes by updating them, but cannot delete them.
If your problem involves mail to root, see also Q0507.