Mailing List Archive

/var/spool/exim/db
Hello,

I've seen some messages on this topic in the mail archives, but seems
like at that time no solution was found. I'm running Exim 3.35. Here's the problem. Today I started seeing these entries in the log:

failed to open database lock file /var/spool/exim/db/wait-remote_smtp.lockfile: Permission denied (euid=8 egid=8)

Here's the directory permissions.

drwxr-xr-x 14 root root 4096 Apr 21 23:57 /var
drwxr-xr-x 7 root root 4096 Jul 25 00:40 /var/spool/
drwxr-x--- 5 mail mail 4096 Mar 11 08:13 /var/spool/exim
drwxr-x--- 2 mail mail 4096 Jul 25 19:44 /var/spool/exim/db

And here are the file permissions withing "/var/spool/db"

-rw-r----- 1 mail root 4096 Jul 11 06:25 wait-remote_smtp
-rw-r----- 1 root root 0 Jul 11 06:25 wait-remote_smtp.lockfile

Naturally, Exim won't be able to open those files, but has anybody found
out why the ownership got changed from mail:mail on those two files?

Can I delete those files and will Exim reproduce them? And what are
they?

Cheers,
Sergei
Re: /var/spool/exim/db [ In reply to ]
> failed to open database lock file
/var/spool/exim/db/wait-remote_smtp.lockfile: Permission denied (euid=8
egid=8)

You could also check the permissions of /var/tmp and /tmp to make sure you
can write to the dir.

A while back I had to do an strace on the delivery exim process and found
that the DB routine tried to access the dir and couldn't, so it gave that
error and sent me on a wild goose chase for 2 months.

-Sam
Re: /var/spool/exim/db [ In reply to ]
> You could also check the permissions of /var/tmp and /tmp to make sure you
> can write to the dir.

Yes, just check them. Both of them have the sticky bit set.

> A while back I had to do an strace on the delivery exim process and found
> that the DB routine tried to access the dir and couldn't, so it gave that
> error and sent me on a wild goose chase for 2 months.

Hey, it's pretty cool that you could diagnose the problem with strace.

Sergei
Re: /var/spool/exim/db [ In reply to ]
On Thu, 25 Jul 2002, Sergei Gerasenko wrote:

> And here are the file permissions withing "/var/spool/db"
>
> -rw-r----- 1 mail root 4096 Jul 11 06:25 wait-remote_smtp
> -rw-r----- 1 root root 0 Jul 11 06:25 wait-remote_smtp.lockfile
>
> Naturally, Exim won't be able to open those files, but has anybody found
> out why the ownership got changed from mail:mail on those two files?

This is an elusive bug that has been reported before, but which I have
never been able to track down, however much I try. It is still on my
list of unexplained funnies. Every now and again I take another look at
it. Maybe one day I'll figure it out...

> Can I delete those files and will Exim reproduce them? And what are
> they?

They are hints files, holding retry information. Yes, you can delete
them.

--
Philip Hazel University of Cambridge Computing Service,
ph10@cus.cam.ac.uk Cambridge, England. Phone: +44 1223 334714.
Re: /var/spool/exim/db [ In reply to ]
> Yes, just check them. Both of them have the sticky bit set.

But make sure it is "drwxrwxrwt". Mine didn't work unless I had EXACTLY
those permissions...

> Hey, it's pretty cool that you could diagnose the problem with strace.

The -d9 option didn't tell me anything, so I did an 'strace ./exim -M msg'
and it gave all the info...specifically that it was trying to access
/var/tmp to work with the DB. Since that is outside of the main exim code,
it wasn't able to produce a specific enough error message.

-Sam