SOLVED Roundcube contacts not restored after account transfer

Vijai

Member
Jul 2, 2016
17
1
3
India
cPanel Access Level
Root Administrator
Hello,
I recently transferred an account using transfer tool from whm and everything works except that I noticed that the roundcube database has not been restored and the log says the database is corrupt? I'm able to browse the database from whm->phpmyadmin fine and can also export it from the old server.

Regards,
Vijai
 

24x7server

Well-Known Member
Apr 17, 2013
1,912
99
78
India
cPanel Access Level
Root Administrator
Twitter

Vijai

Member
Jul 2, 2016
17
1
3
India
cPanel Access Level
Root Administrator
Well, before starting the transfer, I rebuilt the db and then initiated the transfer. It failed despite that. So I just opened phpmyadmin from whm and dumped the roundcube mysql database and have a backup of it now. Will check the logs and post the exact log here once I find something meaningful.

Edit: Here is the log.
Code:
RANSFER: 4 completed, 0 had warnings, and 0 failed.
RESTORE: 4 completed, 1 had warnings, and 0 failed.
RESTORE: Account “user”: Warnings
Removed empty DB for failed restore of “roundcube”.
The system has saved the database archive data in the directory “/home/user/cpmove_failed_mysql_dbs.1511537827”. You may use this directory’s contents to restore your data manually.
This account archive does not contain a domain named “ipv6.domain.com”. The system will not add this domain to the restored account’s AutoSSL exclusions.
The “Roundcube” restore module failed because of an error: The MySQL server reported an error (Table 'contactgroupmembers' already exists) in response to this request: CREATE TABLE `contactgroupmembers` ( `contactgroup_id` int(10) unsigned NOT NULL, `contact_id` int(10) unsigned NOT NULL, `created` datetime NOT NULL DEFAULT '1000-01-01 00:00:00', PRIMARY KEY (`contactgroup_id`,`contact_id`), KEY `contactgroupmembers_contact_index` (`contact_id`), CONSTRAINT `contact_id_fk_contacts` FOREIGN KEY (`contact_id`) REFERENCES `contacts` (`contact_id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `contactgroup_id_fk_contactgroups` FOREIGN KEY (`contactgroup_id`) REFERENCES `contactgroups` (`contactgroup_id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=latin1 at /usr/local/cpanel/Whostmgr/Transfers/SystemsBase/MysqlBase.pm line 280, <$_[...]> line 231.
Surprisingly, I see no database for roundcube in phpmyadmin neither do I see individual user db in
Code:
/home/user/etc/domain
Could the database be dropped since there was an error?
 
Last edited by a moderator:

Vijai

Member
Jul 2, 2016
17
1
3
India
cPanel Access Level
Root Administrator
Hello,
So I opened a support ticket on 25th November and the support representative was provided access to both old and new server. He told that both the server reflects some error while converting the mysql db to sqlite and he's not able to solve it and is escalating the ticket to a L2 analyst. Since then, I'm not able to use webmail (Roundcube was functioning before with just no user data from previous server like identities, signatures and contacts) and shows error.
Code:
[2017-11-28 10:52:21 +0530] info [webmaild] [fcgi] PHP message: PHP Warning:  touch(): Unable to create file /home/admin/etc/domain.com/user.rcube.db because Permission denied in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube_db_sqlite.php on line 38
PHP message: PHP Warning:  file_put_contents(/home/admin/tmp/errors): failed to open stream: Permission denied in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube.php on line 1259
PHP message: PHP Warning:  SQLSTATE[HY000] [14] unable to open database file in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube.php on line 1364
PHP message: PHP Warning:  file_put_contents(/home/admin/tmp/errors): failed to open stream: Permission denied in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube.php on line 1259
PHP message: PHP Warning:  SQLSTATE[HY000] [14] unable to open database file in /usr/local/cpanel/base/3rdparty/roundcube/program/lib/Roundcube/rcube.php on line 1364
Ticket number is: 9059709

Can somebody help me solve this please? Using squirrel mail seems like using 90's webmail client.

Regards,
Vijai

 

Vijai

Member
Jul 2, 2016
17
1
3
India
cPanel Access Level
Root Administrator
That ticket was just closed by you, stating Roundcube was now working. All set?
Yes. You were just right on time. I received a complimentary phone support and the person on phone support solved it. The issue was something to do with right permission not being set. He updated the permissions and forced a roundcube database rebuild using the below command which fixed it.

Code:
/scripts/mailperm
/usr/local/cpanel/bin/update-roundcube-db --force
 
  • Like
Reactions: Infopro