IMAP-Problem: directory is not owned by the correct uid or gid

Discussion in 'Installation/Configuration' started by st2xo, Dec 2, 2008.

  1. st2xo

    st2xo New Member

    I have a problem with the correct uid and gid with Maildir-directories.

    I set up a standard ISPConfig-2.2.25 on Suse11 with Maildir and changed the Userid- and Groupid-Range to both 8000 (ISPConfig Panel Administration/SystemConfig)
    (because of more comfortable restore-possibilities with rsync)

    All ist fine except the login with imap-mail client (I use Squirrel), this error occurs:

    "ERROR: IMAP server closed the connection. Server responded:* BYE [ALERT] Fatal error: Account's mailbox directory is not owned by the correct uid or gid"

    I checked now the uid/gid no /home/www/web2/user:

    drwxr-xr-x 5 web2_info web2 4,0K 21. Okt 17:11 web2_info/
    drwxr-xr-x 5 web2_webmaster web2 4,0K 2. Dez 13:05 web2_webmaster/

    and in /etc/passwd

    admispconfig:x:1003:1003:Administrator ISPConfig:/home/admispconfig:/bin/bash
    ispconfigend:x:20000:20000::/home/ispconfigend:/sbin/nologin
    web2_webmaster:x:8001:8002:webmaster:/home/www/web2:/bin/false
    web2_info:x:8002:8002:info:/home/www/web2/user/web2_info:/bin/false

    in /etc/group:

    users:x:100:web2_info
    admispconfig:x:1003:admispconfig
    ispconfigend:!:20000:
    web2:x:10002:admispconfig,web2_webmaster


    My question - before I´m starting experiments with the uid/gid on the dirs and files - are that settings as above correct?
    Why is the "web2_webmaster" not part of group "users"? Is that correct?
    Is there - or could be - any problem by change die uid/gid-ranges (8000 in my example)

    Thanks for any hints or help!

    (I found this thread t=27618 and have tried the recommended, but no result)
     
  2. falko

    falko Super Moderator

    What's the output of
    Code:
    ls -la /Maildir
    in the home directory of one of the affected users?
     
  3. st2xo

    st2xo New Member

    Hi Falko,

    /home/www/web2/user/web2_info

    drwxr-xr-x 5 web2_info web2 4,0K 21. Okt 17:11 ./
    drwxr-xr-x 12 web2_webmaster web2 4,0K 23. Sep 13:33 ../
    drwx------ 7 web2_info web2 4,0K 21. Okt 17:00 Maildir/
    drwxrwxr-x 2 web2_info web2 4,0K 23. Sep 12:42 web/



    /home/www/web2/user/web2_info/Maildir:

    drwx------ 7 web2_info web2 4,0K 21. Okt 17:00 ./
    drwxr-xr-x 5 web2_info web2 4,0K 21. Okt 17:11 ../
    drwx------ 2 web2_info web2 4,0K 5. Dez 07:27 cur/
    drwx------ 2 web2_info web2 4,0K 5. Dez 09:49 new/
    drwx------ 2 web2_info web2 4,0K 5. Dez 09:49 tmp/


    (all the hidden files are not in the list)

    I already have done chmod 775 on the dirs which are 700 above.
    But no effect, same imap error.

    Meanwhile I have added the users (web2_webmaster, web_info) to the groups "users" and "web2" - no effect, same error
     
    Last edited: Dec 5, 2008
  4. till

    till Super Moderator

    Which IMAP server do you use?
     
  5. st2xo

    st2xo New Member

    courier-imap 4.3.1-18.1,
    (installed with ISPConfig-2.2.25, perfect Suse11 Setup)

    I checked the logging in /var/log/mail:

    http-GET the Squirell-Webmail Interface
    Dec 6 00:50:05 srv2 imapd: Connection, ip=[::ffff:127.0.0.1]
    Dec 6 00:50:05 srv2 imapd: LOGOUT, ip=[::ffff:127.0.0.1], rcvd=30, sent=452


    http-POST the address/password-data:
    Dec 6 00:50:24 srv2 imapd: Connection, ip=[::ffff:127.0.0.1]

    results in the error "ERROR: IMAP server closed the connection. Server responded:* BYE [ALERT] Fatal error: Account's mailbox directory is not owned by the correct uid or gid"

    that is very confusing to me:

    "imapd Connection" und "Logout" with the http-GET and another "imapd Connection" with the http-POST? That looks very strange.

    On another system (older versions, no imap-problem) there is a complete different behaviour in the /var/log/mail with GET the Squirell-Login Form and POST the data ...
     
  6. falko

    falko Super Moderator

    Can you check if web2_info is maybe listed more than once in /etc/passwd?
     
  7. st2xo

    st2xo New Member

    first: sorry for my late answers ...

    both users are listed once in /etc/passwd:
    web2_webmaster:x:8001:8002:webmaster:/home/www/web2:/bin/false
    web2_info:x:8002:8002:info:/home/www/web2/user/web2_info:/bin/false
     
  8. falko

    falko Super Moderator

    Then I'm running out of ideas... :(
     
  9. st2xo

    st2xo New Member

    hope next week to be able to run some tests on this topic.
    (oops - one week to xmas .... )

    First I will "reset" the uid/gid values in
    ISPConfig/Panel Administration/SystemConfig
    to none values or ... ?
    (is it possible to delete the values, so that the field will be empty?)

    If somebody has any ideas, I would be glad for your comments!
    Thanks so far!
     

Share This Page