Koozali.org: home of the SME Server

Dovecot missing +r perm

Offline toothandnail

  • ***
  • 135
  • +0/-0
Dovecot missing +r perm
« on: June 13, 2024, 01:11:26 PM »
A user got a new laptop (Windows 11), created a Thunderbird profile for a number of accounts. All seemed fine until he went back to the desktop machine, and found he could not see any messages in the inbox of his own account. When I checked, all I found in the logs was as below:

Code: [Select]
Jun  5 14:58:43 huntmaster dovecot: imap(xxxxxx): Error: open(/home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb) failed: Permission denied (euid=5000(xxxxxx) egid=5000(xxxxxx) missing +r perm: /home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb)
Jun  5 14:58:43 huntmaster dovecot: imap(xxxxxx): FETCH failed: Internal error occurred. Refer to server log for more information. [2024-06-05 14:58:43] in=325 out=2944248

I borrowed his password and set up a copy of his account (only his main email address) and I'm getting exactly the same problem - I can see sent messages, spam and deleted messages, just nothing in the inbox. Apparently he can still access his email from Thunderbird on the laptop, or Outlook, but any new account can't see the messages (3,500+ of them) in his inbox.

It looks as though Thunderbird did something nasty in the new profile he built, but I have searched on the "missing +r perm" error, and not found any fixes for it. I'm hoping someone can tell me what I need to do to fix it. It looks as though some of the dovecot indexes are messed up - looking at his account through Horde shows a number of invalid entries for older messages.

I've found ways of regenerating the indexes, but nothing much for the missing +r perm error. Any suggestions gratefully accepted...


Offline Stefano

  • *
  • 10,874
  • +3/-0
Re: Dovecot missing +r perm
« Reply #1 on: June 13, 2024, 05:05:30 PM »
please, post the output of

Code: [Select]
ls -la /home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb

thank you

Offline toothandnail

  • ***
  • 135
  • +0/-0
Re: Dovecot missing +r perm
« Reply #2 on: June 13, 2024, 05:24:21 PM »
please, post the output of

Code: [Select]
ls -la /home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb

thank you

As below:

Code: [Select]
[root@huntmaster cur]# ls -la /home/e-smith/files/users/xxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb
-rw------- 1 root root 1946056 Nov 26  2021 /home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb

Its the only message in his inbox with owner and group set to root. Its been there for quite a while as well. I would never have known to look for it..

Offline Stefano

  • *
  • 10,874
  • +3/-0
Re: Dovecot missing +r perm
« Reply #3 on: June 13, 2024, 05:38:13 PM »
well

Code: [Select]
chown user:user /home/e-smith/files/users/xxxxxx/Maildir/cur/1637923626.31850.huntmaster:2,Sb

where user = xxxxxx
should do the trick