Migration from ispCP 1.1.0 database key files corrupted

  • Hi all,

    as this thread is marked as solved, I opened a new thread.
    Migrating from ispCP 1.1.0 -> All ispCP database key files are corrupted

    I basically do have the same problem as described in above thread, but I can't find any hints in wiki or elsewhere, what to do in this case. So: can someone help me with this issue, how to regenerate the db key files? I work on a clone of my still productive ispCP server, so no worries if something goes wrong (ESXi, Snapshots...)



  • Sorry for pushing this, but why doesn't anyone answer this question, when there already seems to be a solution and a howto that has somehow disappeared?
    If you expect me to pay something, just tell me, that shouldn't be the problem, as I am willing to back the i-MSCP project in case everything works and I am satisfied with the product.

  • Because not everybody knows the answer :) Think @Nuxwin is atm the only one who has already found a solution, but also busy.

  • @-bk-

    If you really wait an answer from us, you should start by providing the error log. Saying I basically do have the same problem as described in above thread is not sufficient. According the error message, we'll give you an answer.


  • Thanks for your reply.
    Error log /var/log/imscp/imscp-migrate-from-ispcp.log

    1. [Wed Dec 10 11:46:13 2014] [debug] iMSCP::Debug::verbose: Debug mode off
    2. [Wed Dec 10 11:46:16 2014] [error] main::checkDbPassword:
    3. Unable to connect to the ispCP database using the /etc/ispcp/ispcp-keys.conf file
    4. [Wed Dec 10 11:46:19 2014] [error] iMSCP::Debug::END: Exit code: 1
  • Re;

    Try the following:

    1. Remove the following files manually if any

    1. # rm -f /etc/ispcp/ispcp-keys.conf# rm -f /var/www/ispcp/gui/include/ispcp-db-keys.php# rm -f /var/www/ispcp/engine/ispcp-db-keys.pl# rm -r /var/www/ispcp/engine/messenger/ispcp-db-keys.pl

    2. Copy key templates files from the ispCP archive (1.0.7) - Download it and unpack it first if needed

    1. # cp <ispcp_archive_dir>/gui/include/ispcp-db-keys.php /var/www/ispcp/gui/include/ispcp-db-keys.php# cp <ispcp_archive_dir>/engine/ispcp-db-keys.pl /var/www/ispcp/engine/ispcp-db-keys.pl# cp <ispcp_archive_dir>/engine/ispcp-db-keys.pl /var/www/ispcp/engine/messenger/ispcp-db-keys.pl

    Note: You must replace <ispcp_archive_dir> by the path to your ispCP archive directory

    3. Edit the /etc/ispcp/ispcp.conf file and remove the value for the DATABASE_PASSWORD parameter
    4. Run the /var/www/ispcp/engine/ispcp-db-passwd script and answer the questions:

    1. # perl /var/www/ispcp/engine/ispcp-db-passwd

    Note: The entered password must be the current SQL root user password. Thus, before doing the steps above, you must ensure that the password is working. If you do not know the SQL root user password, update it as follow:

    1. # dpkg-reconfigure mysql-server-5.1

    Note: You must adjust the mysql-server-5.1 package name according the MySQL server version you are using.

    Once it's done, rerun the i-MSCP migration script.


  • Wait something is missing in my instructions ;)

    Edit: Previous post updated.


  • Hello Nuxwin,
    thank you for your quick response. Unfortunately, the installer aborts with the same error message

    1. root@ispcp:/var/www/imscp/engine/setup# cat /var/log/imscp/imscp-migrate-from-ispcp.log
    2. [Wed Dec 10 13:01:53 2014] [debug] iMSCP::Debug::verbose: Debug mode off
    3. [Wed Dec 10 13:01:58 2014] [error] main::checkDbPassword:
    4. Unable to connect to the ispCP database using the /etc/ispcp/ispcp-keys.conf file
    5. [Wed Dec 10 13:02:00 2014] [error] iMSCP::Debug::END: Exit code: 1

    Do I need to delete / modify /etc/ispcp/ispcp-keys.conf ?

    EDIT: Reading the updated instructions

  • Re;

    Remove the /etc/ispcp/ispcp-keys.conf file.


  • I executed the first instruction, without your addition :-)
    Trying your updated instruction first. One thing I saw is that in the newly downloaded ispcp 1.0.7 sources, the file <ispcp_archive>_dir>/engine/messenger/ispcp-db-keys.pl does not exist
    Trying it first, if this does not work, I will give you access. As this is a test migration and not the live system, I would like to succeed myself so I can do the live migration as well