Hello
You can manually mark the transfer as completed using the following instructions:
1. Ensure the transfer is no longer running by clicking on the “View” option under "Sessions in Progress" for this transfer. In the new window, there will be a line that looks like this:
Code:
You may close this window and view the transfer on the command line: /usr/local/cpanel/bin/view_transfer 1054056copya201407021337529eG8A76iJY
Access your server via SSH and run that command (the transfer name will be different on your server):
Code:
/usr/local/cpanel/bin/view_transfer 1054056copya201407021337529eG8A76iJY
As an example, you might see output like this:
Code:
Transfer running with pid: 795
[795 ][MASTER ]: Start Session
[795 ][MASTER ]: Version: 1.9
[795 ][MASTER ]: Queue “TRANSFER” items: 1
[795 ][MASTER ]: Queue “RESTORE” items: 1
[795 ][MASTER ]: Remote Host: 10.1.1.1
[797 ][TRANSFER:1 ]: Starting Account: “cptest”
[797 ][TRANSFER:1 ]: Account “cptest”: success
[797 ][TRANSFER:1 ]: Progress: 100%
[797 ][TRANSFER:1 ]: Child Complete
[ERROR ][MASTER ]: Error: Cpanel::DBI::Mysql connect('','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at /usr/local/cpanel/Cpanel/MysqlUtils/Connect.pm line 42
[ERROR ][MASTER ]: Error: Cpanel::DBI::Mysql connect('','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at /usr/local/cpanel/Cpanel/MysqlUtils/Connect.pm line 42
You will note that the master PID for this transfer is 795. If the process still exists, and the transfer has failed, then you can kill that process:
2. The next step requires you to change the entry for this transfer in the whmxfer.sessions table in MySQL. Find the entry with the session ID for your migration. In the example we have been using, it's '1054056copya201407021337529eG8A76iJY.' It will look like this:
Code:
-bash-4.1# mysql -e "select * from whmxfer.sessions where sessionid='1054056copya201407021337529eG8A76iJY'"
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------+
| sessionid | initiator | pid | version | target_host | source_host | state | starttime | endtime |
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------+
| 1054056copya201407021337529eG8A76iJY | copyacct | 795 | 1.9 | hostname.server | 10.1.1.1 | 20 | 2014-07-02 08:37:52 | NULL |
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------+
You will need to change the 'state' field to 100, and change the 'endtime' field from NULL to a time after the 'starttime' field:
Code:
-bash-4.1# mysql -e "update whmxfer.sessions set state='100', endtime='2014-07-02 09:37:52' where sessionid='1054056copya201407021337529eG8A76iJY'"
Thus, the output then looks like this:
Code:
-bash-4.1# mysql -e "select * from whmxfer.sessions where sessionid='1054056copya201407021337529eG8A76iJY'"
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------------------+
| sessionid | initiator | pid | version | target_host | source_host | state | starttime | endtime |
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------------------+
| 1054056copya201407021337529eG8A76iJY | copyacct | 795 | 1.9 | hostname.server | 10.1.1.1 | 100 | 2014-07-02 08:37:52 | 2014-07-02 09:37:52 |
+--------------------------------------+-----------+------+---------+---------------------------+-------------+-------+---------------------+---------------------+
The transfer should then no longer appear under "Sessions in Progress."
Thank you.