SOLVED Server Error in Webmail Inbox after transfer from another cPanel account

Feb 14, 2017
5
1
3
UK
cPanel Access Level
Reseller Owner
I am transferring 5 email accounts from one cpanel hosting account to another. I created all the email accounts in the new cpanel hosting account and then copied the mail and the etc folders from the old hosting. All the emails appear to be there but I have opened webmail to check before changing the DNS. Four of the email accounts work fine but the largest one is showing a server error in the inbox, the error says "Server Error! (OK)".

Any help would be much appreciated.
Gale
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello,

You can try running the following command to ensure mailbox permissions are correct:

Code:
/scripts/mailperm $username
Also, do you notice any specific output to /usr/local/cpanel/logs/error_log or /var/cpanel/roundcube/log/errors (when using Roundcube) when this happens?

Thank you.
 
Feb 14, 2017
5
1
3
UK
cPanel Access Level
Reseller Owner
My hosting company has updated the permissions for me but this doesn't seem to have fixed the problem.
I have looked for the error logs at the paths you quoted above but I can't seem to find them. I have a logs file here /home/iseasurf/logs but I can't see any reference to errors or error_log
Thank you for your help.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello,

You won't have access to those logs as a reseller. Your hosting provider will need to review those logs to determine the cause of the problem.

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
I'm happy to see the issue is now resolved. Thank you for updating us with the outcome.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Can you please let me know which dovcot.index file you deleted? Like which folder is it located in?
You'd generally remove the dovecot.index file that's located in the directory associated with the affected email account. EX:

Code:
/home/$username/mail/$domain.com/$email-account-name/dovecot.index
You can also remove the files for a cPanel account through the following command if you have root access to the server:

Code:
/scripts/remove_dovecot_index_files --user $username
Thank you.
 

Fortunatus

Registered
May 10, 2018
3
0
1
Tanzania
cPanel Access Level
Reseller Owner
Hello,

You can try running the following command to ensure mailbox permissions are correct:

Code:
/scripts/mailperm $username
Also, do you notice any specific output to /usr/local/cpanel/logs/error_log or /var/cpanel/roundcube/log/errors (when using Roundcube) when this happens?

Thank you.
Hello Michael.. I am facing the same issue now.. i migrated email files from inmotion to hostgator and now am receiving server error when accessing ROUNDCUBE and OUTLOOK.. emails take long to load.. please help me Michael
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello Michael.. I am facing the same issue now.. i migrated email files from inmotion to hostgator and now am receiving server error when accessing ROUNDCUBE and OUTLOOK.. emails take long to load.. please help me Michael
Hello @Fortunatus,

Your access level in your forum profile shows as "Reseller Owner". Do you have root access to either of these servers, or do you have reseller access only?

Thank you.
 

Fortunatus

Registered
May 10, 2018
3
0
1
Tanzania
cPanel Access Level
Reseller Owner
Hello @Fortunatus,

Your access level in your forum profile shows as "Reseller Owner". Do you have root access to either of these servers, or do you have reseller access only?

Thank you.
Hello Michael.. I bought a baby cloud site from hostgator.. So i have only access to the control panel.. Is that a root password you are asking? Or I should ask hostgator to give me root access.. I migrated emails from inmotion to hostgator.. thats when the problem starts..
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello,

The cloud plans they provide offer root access as far as I know. Check with their support team for information on how you can access your server via SSH as the "root" user, as you'll need to do that in order to troubleshoot the issue.

Thank you.
 

Fortunatus

Registered
May 10, 2018
3
0
1
Tanzania
cPanel Access Level
Reseller Owner
Hello,

The cloud plans they provide offer root access as far as I know. Check with their support team for information on how you can access your server via SSH as the "root" user, as you'll need to do that in order to troubleshoot the issue.

Thank you.
I have asked them.. Looks like they dont provide user access as root.. But i can login through ssh using my cpanel user and password which i have tried already.. gives the same files as i can access through "file manager" in cpanel.. They only offer root access for dedicated and VPS.. what can I do now? Thank you..
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
I have asked them.. Looks like they dont provide user access as root.. But i can login through ssh using my cpanel user and password which i have tried already.. gives the same files as i can access through "file manager" in cpanel.. They only offer root access for dedicated and VPS.. what can I do now? Thank you..
Hello,

I recommend reaching out to their support team to report the issue with your emails so they can access the server from the root level to investigate further.

Thank you.
 

katmai

Well-Known Member
Mar 13, 2006
564
4
168
Brno, Czech Republic
heyaz @cPanelMichael - i am experiencing the same issue in roundcube /var/cpanel/roundcube/log/errors shows nothing and neither /usr/local/cpanel/logs/error_log

- a little more context: the error happens for only a few e-mails, not for every e-mail.
- if i switch to horde - the e-mails that show the error on roundcube display just fine.

i did upcp --force,
/scripts/remove_dovecot_index_files --user myusername
/scripts/mailperm myusername

also tried reinstalling roundcube
rpm -e --nodeps cpanel-roundcubemail
/usr/local/cpanel/scripts/check_cpanel_rpms --fix

as well as forced update on the roundcube db
/usr/local/cpanel/bin/update-roundcube-db --force

but still getting the same error in roundcube. any ideas?

i am running the latest and greatest cpanel - 78.0.15
thanks in advance,
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
i am experiencing the same issue in roundcube /var/cpanel/roundcube/log/errors shows nothing and neither /usr/local/cpanel/logs/error_log
Hi @katmai,

Can you report this behavior in a support ticket and post the ticket number here? I'll link this thread to the ticket.

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
thanks @cPanelMichael - 11605889 - ticket number
Hello,

To update, here's a response from one of our Technical Analysts on this ticket explaining the cause of the issue:

The reported behavior is caused by invalid MIME types in the header information that are not recognized by the IMAP services. In some cases, this can be caused by message data corruption but is most commonly caused by the headers generated on the remote mail server. While it is recommended that this issue is addressed by ensuring messages sent from the remote location meet RFC standards, Dovecot's imap_capability configuration option can be modified if you wish to make non-RFC compliant messages readable by Dovecot/Roundcube or in the event mail data has become corrupt. Ultimately, the choice of how to handle this and whether or not to use the configuration is up to you as this is not caused by a defect in the software.

For additional information regarding this, I'd suggest referring to the following documentation:
RFC 5228 - Sieve: An Email Filtering Language
The specific modification referenced in the quote above was to change the following configuration value:

Code:
  # Override the IMAP CAPABILITY response. If the value begins with '+',
  # add the given capabilities on top of the defaults (e.g. +XFOO XBAR).
[%- IF protocol_imap.imap_capability.defined %]
  imap_capability = [% protocol_imap.imap_capability %]
[%- ELSE %]
  #imap_capability =
[%- END %]
To:

Code:
  # Override the IMAP CAPABILITY response. If the value begins with '+',
  # add the given capabilities on top of the defaults (e.g. +XFOO XBAR).
[%- IF protocol_imap.imap_capability.defined %]
  imap_capability = "IMAP4rev1 SASL-IR LOGIN-REFERRALS ID ENABLE IDLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS THREAD=ORDEREDSUBJECT MULTIAPPEND URL-PARTIAL CATENATE UNSELECT UIDPLUS +NAMESPACE"
[%- ELSE %]
  #imap_capability =
[%- END %]
The Add Dovecot Options section on our MailServer Configuration document explains how to modifications like this to the Dovecot configuration file.

Thank you.
 

Rolando Lopez

Registered
Apr 1, 2019
3
1
3
Mexico
cPanel Access Level
Root Administrator
I am transferring 5 email accounts from one cpanel hosting account to another. I created all the email accounts in the new cpanel hosting account and then copied the mail and the etc folders from the old hosting. All the emails appear to be there but I have opened webmail to check before changing the DNS. Four of the email accounts work fine but the largest one is showing a server error in the inbox, the error says "Server Error! (OK)".

Any help would be much appreciated.
Gale
if you Suddenly get "Error from server: UID SORT", verify is there is not Cero bytes files in user´s /cur directory and manually detele them with command "find . -size 0c -delete "