Current KB applies to migration of Linux-based POA Management Node form hosts running RHEL/CentOS 4.x to hosts running RHEL/CentOS 5.x. It contains latest migration scripts, instructions and known issues.

Migration scripts

ZIP archive containing latest backup script and OA Updater RPM (restore script) is attached. To use the latest migration scripts perform the following before OA MN migration:

  1. Upload attached POA\MN\Migration\<version>.ZIP to OA MN

  2. Extract ZIP contents

  3. Upgrade OA Updater RPM package to one from current archive (use MN OS correponding RPM package)

  4. Backup /usr/local/pem/bin/backup.sh file

  5. Replace /usr/local/pem/bin/backup.sh file with one from ZIP archive

Migration instructions

OA 5.5 instruction see here.

Known issues

  1. POA-82594 Migration could fail due to violation of package dependency

    Symptom

    During restore procedure the following error may occur during SaaS reinstall:

    2014-11-11 11:18:51.618  WARN Package 'SaaS' failed to re-install due to error: ['/usr/local/pem/bin/ppm_ctl', '-f', '/usr/local/pem/etc/pleskd.props', '-b', '-q', 'reinstall', '1', '3023'] exited with non-zero status 1
    Ignore this package and continue migration?
    ((Y)es/(N)o): n
    

    In /var/log/poa-migrate.log:

    ERROR [xinstallPackage] ExSystem: module_id:'PPM', ex_type_id:'3110',Message:'Command '/usr/local/pem/bin/saas_ctl upgrade_aps_db ../APS/database' execution failed with code 127: /usr/local/pem/bin/saas_ctl: error while loading shared libraries: libboost_regex.so.1.41.0: cannot open shared object file: No such file or directory', deprecated_codes = (0, 0), properties = { exit_code: '127',command: '/usr/local/pem/bin/saas_ctl upgrade_aps_db ../APS/database',stderr: '/usr/local/pem/bin/saas_ctl: error while loading shared libraries: libboost_regex.so.1.41.0: cannot open shared object file: No such file or directory', }
    

    Cause

    During MN restore OA PPM packages are being re-installed. Packages may be re-installed in wrong order.

    Solution

    1 Re-create OA MN backup using latest migration scripts.

    2 If still no luck then perform the following:

    In OA DB get component IDs:

    plesk=> SELECT component_id, name FROM packages p JOIN components c ON (c.pkg_id = p.pkg_id) JOIN hosts h ON (c.host_id = h.host_id) WHERE c.uninstalled = 'n' AND h.host_id = 1 and name in ('libvirtualization', 'libservices');
    component_id  |       name        
    --------------+-------------------
    3508          | libservices
    3759          | libvirtualization
    (2 rows)
    

    Execute the following commnads (specify component IDs from the previous query result):

    /usr/local/pem/bin/ppm_ctl -f /usr/local/pem/etc/pleskd.props -b -q reinstall 1 3508
    /usr/local/pem/bin/ppm_ctl -f /usr/local/pem/etc/pleskd.props -b -q reinstall 1 3759
    

    Restart the migration

  2. POA-82606 POA migration script does not create redis services on destination POA MN

    Symptom

    NG Web Hosting is used on installation

    Solution

    1. Create OA MN backup using latest migration scripts

    2. Restore OA MN in accordance with instructions

    3. Execute

      sh POA_backup/redis_restore-<time stamp>.sh
      
    4. Login to OA CP as admin and perform NG cluster database sync
  3. POA-85511 Migration of Management Node from RHEL/CentOS 4.x does not migrate SSH keys

    Solution

    Use latest migration scripts or manually copy SSH keys.

  4. POA-83840 MN RHES4-CentOS6 migraton fails to reinstall package: Attempt to add package with bad signature

    Solution

    Ignore failed action. OA 5.5.8 will fix the issue permanently.

  5. POA-82595 POA migration fails due to missing pgsql_firewall.sh

    Symptom

    2013-12-12 00:02:31.651 ERROR ExecFailed ['sh', '/root/POA_backup/pgsql_firewall.sh'] exited with non-zero status 127
    2013-12-12 00:02:31.651 ERROR <class 'poaupdater.uUtil.ExecFailed'>
    

    Solution

    1. Grab /usr/local/pem/bin/pgsql_firewall.sh script from old OA installation and put it into POA_backup directory

    2. Rerun restore
  6. WAP RPM is not installed to OA MN automatically after the migration.

    Solution

    1. Obtain the same version of WAP RPM as installed on the source OA MN server and install it
    2. Copy the folder /usr/local/share/WAP from the source OA MN
    3. Restart WAP:

      # service WAP restart
      
  7. After the migration is done, set onboot parameter to no for the source container (if MN was running inside the container):

    # grep -ri boot /vz/private/10/ve.conf
    ONBOOT="yes"
    # vzctl set 10 --onboot no --save
    Saved parameters for Container 10
    
  8. There should be no packages of type service on POA MN except for PrivacyProxy. The script checks it using the following query:

    ++ psql -Uplesk -hlocalhost -d plesk -tAc 'SELECT STRING_AGG(name, '\'', '\'') FROM services WHERE host_id = 1 AND name NOT IN ('\''PrivacyProxy'\'');'
    

    Therefore, if there are some services present on the Management Node (usually - logparser, proftpd, etc), they should be deleted from POA MN before migration.

  9. backup.sh could fail with the following error:

    dumping global objects
    server version: 9.1.6; pg_dumpall version: 8.1.11 aborting because of version mismatch  (Use the -i option to proceed anyway.) backup.sh error: failed to dump global pgsql objects
    

    It fails because the version of pg_dumpall is too old. To fix the error, please reinstall the package postgresql91* on the POA Management Node.

  10. Restoration can fail with the following error:

    2015-07-01 04:19:37.134  WARN Package 'PrivilegesEvents' failed to re-install due to error: ['/usr/local/pem/bin/ppm_ctl', '-f', '/usr/local/pem/etc/pleskd.props', '-b', '-q', 'reinstall', '1', '61'] exited with non-zero status 1
    

    In /var/log/poa-migrate.log:

    ERROR [xinstallPackage] ExSystem: module_id:'db_service', ex_type_id:'1',Message:''ERROR:  permission denied for relation dual;
    Error while executing the query' while ' INSERT INTO privilege_groups(name, mode) SELECT ?, ? FROM dual WHERE NOT EXISTS (SELECT 1 FROM privilege_groups WHERE name = ? )'', deprecated_codes = (0, 0), properties = { sqlcode: 'HY000',reason: 'ERROR:  permission denied for relation dual;
    Error while executing the query',action: ' INSERT INTO privilege_groups(name, mode) SELECT ?, ? FROM dual WHERE NOT EXISTS (SELECT 1 FROM privilege_groups WHERE name = ? )', }
    TRACE [xinstallPackage] <=== EXIT [1.297927]
    

    Solution

    1. log in to psql with posgresq user:

      psql -U postgres -h `hostname` plesk
      
    2. assign all permissions for the user plesk to dual table:

      plesk=# GRANT ALL PRIVILEGES ON TABLE dual to plesk;
      GRANT
      
    3. retry the above-mentioned operation
  11. Re-installation of redis package can fail with the following error:

    2015-07-01 04:31:18.927  INFO Reinstall package (other-redis-2.4.12) to host 1
    2015-07-01 04:31:29.439  WARN Package 'redis' failed to re-install due to error: ['/usr/local/pem/bin/ppm_ctl', '-f', '/usr/local/pem/etc/pleskd.props', '-b', '-q', 'reinstall', '1', '6214'] exited with non-zero status 1
    

    Solution

    1. assign correct ownership to redis.conf file:

      chown redis:redis /etc/redis.conf
      
    2. retry the above-mentioned operation
  12. POA-99598 Not possible to migrate management node

    Symptoms:

    The following error occurs:

    ERROR IOError [Errno 2] No such file or directory: './upgrade/update.udl2'
    

    Workaround:

    Create subdirectory 'upgrade' in directory where 'install.py' script is located and create file 'update.udl2' in that subdirectory with next content:

    <UDL2 name="poa-6.0" />
    

    You could use following commands as example:

    # mkdir upgrade
    # echo "<UDL2 name=\"poa-6.0\" />" > upgrade/update.udl2
    

Limitations of the migration procedure

  1. It is not possible to store MN backup on separate server (i.e. no remote backup/remote restore allowed)
  2. Migration scripts moves both MN itself and database to one server. Therefore, if OA MN has remote DB, the following steps should be performed:

    • assign the IP address allocated for the remote DB server to the destination MN server
    • if it is changed, reflect these changes in the file /usr/local/pem/etc/odbc.ini
    • if required, after the migration is performed, split MN and DB using the article https://kb.cloudblue.com/113830
  3. backup.sh script does not compress data significantly, so the approximate size of the backup equals the size of DB + /usr/local/pem folder. Some unneeded directories inside /usr/loca/pem can be excluded from the backup using -x parameter.

Internal content

Link on internal Article