Overview
In some Webuzo installations, email accounts may show higher disk usage than the actual mail stored on disk.
This issue occurs when duplicate INBOX mailboxes are created with an INBOX. prefix (for example: INBOX.Inbox, INBOX.Inbox.test_inbox).
This causes Dovecot to count the main INBOX twice, inflating the email quota usage shown in Webuzo
Procedure
Follow the steps below to fix the incorrect disk usage.
Step 1 : Identify Duplicate INBOX Mailboxes
doveadm mailbox list -u "username@domain.tld"Example Output
INBOX # Normal Inbox
INBOX.Archive
INBOX.Inbox # Duplicate INBOX counting disk usage twice
INBOX.Inbox.test_inbox
INBOX.spam
INBOX.Trash
INBOX.Sent
INBOX.Junk
INBOX.DraftsIf you see folders beginning with INBOX.INBOX or INBOX.Inbox, duplication exists.
Step 2 : Rename the Mailboxes Without INBOX. Prefix
Navigate to the user’s Maildir:
cd /home/USERNAME/mail/DOMAIN/USER/Rename the duplicated mailbox to anything except INBOX.
mv INBOX.Inbox old.InboxStep 3 : Recalculate User Quota
After mailbox cleanup, recalculate quota using Dovecot:
doveadm quota recalc -u "username@domain.tld"