[afnog] exim cannot chdir to Maildir when with userdb

Fisayo Adeleke fisayo at exnesys.com
Sat Jul 15 10:25:59 EAT 2006


Quoting Brian Candler <B.Candler at pobox.com>:

> On Fri, Jul 14, 2006 at 06:01:01PM +0100, Fisayo Adeleke wrote:
>> [root at spider exim]# LOG: MAIN
>>   == user at domain.com R=courier T=local_delivery_courier defer (13): 
>> Permission
>> denied: cannot chdir to /usr/exim/mailusersdb/s/domain.com/user/Maildir/
>
> First thing is to check the obvious. Show the output of:
>
> ls -ld /usr
> ls -ld /usr/exim
> ls -ld /usr/exim/mailusersdb
> ls -ld /usr/exim/mailusersdb/s
> ls -ld /usr/exim/mailusersdb/s/domain.com
> ls -ld /usr/exim/mailusersdb/s/domain.com/user
> ls -ld /usr/exim/mailusersdb/s/domain.com/user/Maildir
>

I did that and I have this:

[root at spider root]# ls -ld /usr
drwxr-xr-x   17 root     root         4096 Aug 10 07:41 /usr
[root at spider root]# ls -ld /usr/exim
drwxr-xr-x    5 root     exim         4096 Aug 11 17:36 /usr/exim
[root at spider root]# ls -ld /usr/exim/mailusersdb/
drwxr-xr-x    3 root     exim         4096 Aug 11 17:36 /usr/exim/mailusersdb
[root at spider root]# ls -ld /usr/exim/mailusersdb/s
drwxr-xr-x    3 root     exim         4096 Aug 11 17:36 
/usr/exim/mailusersdb/s
[root at spider root]# ls -ld /usr/exim/mailusersdb/s/domain.com/
drwxr-xr-x    3 root     exim         4096 Aug 11 17:36
/usr/exim/mailusersdb/s/domain.com
[root at spider root]# ls -ld /usr/exim/mailusersdb/s/domain.com/user
drwxr-xr-x    3 root     exim         4096 Aug 11 17:37
/usr/exim/mailusersdb/s/domain.com/user
[root at spider root]# ls -ld /usr/exim/mailusersdb/s/domain.com/user/Maildir
drwx------    5 root     exim         4096 Aug 11 17:37
/usr/exim/mailusersdb/s/domain.com/user/Maildir


> If you can 'su' to the exim user, that's another approach (i.e. you can try
> to cd into each of these directories yourself)

When I su to the exim user, it changes to all of the directories one after the
other until I got to the Maildir directory

[root at spider root]# su exim
bash-2.05b$
bash-2.05b$ cd /usr/exim
bash-2.05b$ cd /usr/exim/mailusersdb
bash-2.05b$ cd /usr/exim/mailusersdb/s
bash-2.05b$ cd /usr/exim/mailusersdb/s/domain.com
bash-2.05b$ cd /usr/exim/mailusersdb/s/domain.com/user
bash-2.05b$ cd /usr/exim/mailusersdb/s/domain.com/user/Maildir
bash: cd: /usr/exim/mailusersdb/s/domain.com/user/Maildir: Permission denied
bash-2.05b$ exit
exit
[root at spider root]#

>
> Also, make sure you don't have two users called 'exim' in the passwd file
> with different uids, or two groups called 'exim' in the groups file with
> different gids.

I checked this and there's only one exim user...well, exim was installed as a
normal user called 'normal' which belongs to the exim group, in /etc/group,
does this count as two different uids for exim?

exim:x:90:normal

Thanks,

Fisayo
>
> Regards,
>
> Brian.
>






More information about the afnog mailing list