LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   newbie: dovecot 2.0 error (https://www.linuxquestions.org/questions/linux-newbie-8/newbie-dovecot-2-0-error-937694/)

tonj 04-02-2012 10:39 AM

newbie: dovecot 2.0 error
 
dovecot-2.0.9-2.el6_1.1.i686
on centos 6.2 server install
trying to set up dovecot but I get the following error in my maillog:
dovecot: pop3(username): Error: user username: Initialization failed: Initializing mail storage from mail_location setting failed: mkdir(/home/username/mail) failed: Permission denied (euid=500(username) egid=500(username) missing +w perm: /home/username, euid is not dir owner)
I can see the location /home/username needs write permissions but nothing works in resolving this error. The username in question can receive mail no problem but picking it up with dovecot is where I'm stuck. I don't know what euid and guid means. Can anyone tell me what command I need to run to give this folder the correct permissions? And who should be the group owner of this folder? I've been on this for days and google only has stuff on obsolete dovecot versions. Thanks for any help.

tonj 04-02-2012 02:39 PM

typical...I work on something all week and then an hour after posting here for help I manage to solve it. I did it by creating the directory tree myself ie:
/home/username/mail/.imap/INBOX
this is the directory tree dovecot wanted.

griswald 04-03-2012 10:28 AM

You may still have an underlying issue: the user may not own and cannot write to their own directory: "500" means the owner has read (4) + execute (1) permissions, but no write.
Check by typing:
ls -ld /home/username

To fix, type (as root):
chmod u+w /home/username

If the owner is not "username":
chown username /home/username

FYI euid is the effective uid (user number) and egid the effective gid (group number).

tonj 04-05-2012 11:59 AM

thanks for your response griswald, you were right and I did still have an underlying issue: I found the source of the whole problem, which was selinux. I changed /etc/selinux/config from 'enforcing' to 'permissive' and now the whole thing works perfectly.


All times are GMT -5. The time now is 11:43 AM.