Resolving Disk Quota Issues After Server Migration in cPanel
After transferring an account from one server to another or when migrating a new user, you might encounter discrepancies in the reported disk space usage or a disk quota error. To investigate this issue, you can use the following command to generate a list of all files on the server owned by the account:
find / -user 'username' | du -sh
Review the output to determine if files are stored in folders outside their home directory, potentially consuming additional space.
If after verifying the files everything seems to be in order but the space usage reported by cPanel still appears incorrect, you can execute the commands below to correct the quota calculations:
Generate accurate mail directory sizes:
/scripts/generate_maildirsize --verbose --allaccounts --force --confirm
Correct the quota settings:
/scripts/fixquotas
Remove outdated maildirsize files to prevent conflicts:
find /home/username/mail/ -name maildirsize | xargs rm -f
After running these three commands, the disk quotas in cPanel should accurately reflect the actual disk usage.
If you need assistance, our sysadmins are ready to help. You can also seek support in our Community Forums. For customers of our Business cPanel Hosting solution or any other Managed service experiencing issues, feel free to contact us. Our System Administrators will offer the best assistance available.