BILLmanager 6

Migration between servers

The instructions in this article are suitable for migrating BILLmanager from CentOS 7 to AlmaLinux. For more information about supported operating systems, see Server requirements.

This article describes the process of migration of BILLmanager and its license between servers. This procedure may be required, for example, if you change equipment or need to migrate the platform to a supported OS.

The migration will require connecting to the servers via SSH and copying files between servers. For more information about connecting via SSH, see Workstation setup.

You can migrate between servers with different operating systems.

The version of BILLmanager on the new server must be no lower than on the old server.

To migrate BILLmanager you need to:

  1. Prepare a new server.
  2. Enable platform maintenance mode on the old server for the duration of the migration.
  3. Import user data from the old server to the new one.
  4. Migrate custom XML files, addons and plugins to the new server.
  5. Migrate the storefront settings.
  6. Install missing software packages (service processing modules, payment systems, mail gateways).
  7. Link the BILLmanager license to the new server.
  8. Disable platform maintenance mode on the old server.
After migrating BILLmanager, we recommend disabling or uninstalling the platform from the old server. The same service processing module settings in two BILLmanagers will lead to incorrect opening of services.

Preparation

  1. Install BILLmanager on the new server. Read more in Installation process.
  2. Activate a trial license on the new server via the ISPsystem client area. Read more in Types of licences.
    1. Open BILLmanager in a browser at https://<IP_server_address>:1500/billmgr.
    2. On the activation form, select the "Get trial version" option.
    3. In the field that appears, enter the email address of the account in the ISPsystem client area and password.

    Each server must have an active license at the time of migration.

    The trial license has a limit on the number of clients. After migrating BILLmanager, activate a commercial license on the new server.

    Step 1. Enable maintenance mode

    Maintenance mode switches BILLmanager into maintenance mode. While this mode is enabled, processing modules and mail gateways in BILLmanager will not perform operations.

    To enable maintenance mode on the old server, create an empty file /usr/local/mgr5/etc/billmgr.DoNothing.

    Step 2. Import data

    1. On the old server:
      1. Create a backup:
        1. In the web interface of BILLmanager, enter Tool → Backups. Read more in Backup configuration.
        2. Create a backup by clicking Start.
        3. Save the backup archive by selecting the backup you created in the list and clicking Download.
      2. Save the branding settings. You can skip this step if you have not changed the layout of the BILLmanager web interface. Read more in Branding.
        1. Copy the directories to the new server:

          scp -r /usr/local/mgr5/skins/dragon/local_* root@<IP-address_of_new_server>:/usr/local/mgr5/skins/dragon/
        2. Copy the configuration file to the new server:

          scp /usr/local/mgr5/etc/brand_settings.billmgr.xml root@<IP-address_of_new_server>:/usr/local/mgr5/etc/
    2. On the new server:
      1. Enter ToolsBackups → click Download
        1. Select the backup archive you downloaded from the old server.
        2. Select the downloaded backup and click Restore.
        3. Wait for the restore operation to complete. The system will display a completion notification in the BILLmanager web interface.
      2. After restoring from a backup on the new server, the IP address from the old server will be specified in the configuration file.
        To make BILLmanager available on the new server, specify the IP address of the new server in the configuration ihttpd file /usr/local/mgr5/etc/ihttpd.conf. Read more inControl panel address.
      3. Check that the /usr/local/mgr5/etc/billmgr.pem file has been successfully migrated.
      4. Restart BILLmanager:

        /usr/local/mgr5/sbin/mgrctl -m billmgr exit


    The tariffs, message templates and documents you have created are stored in the BILLmanager database and will be migrated along with the database.

    Step 3. Migrate custom XML files, addons, plugins, icons

    If you have created custom XML files, addons, plugins, icons, to migrate them to the new server:

    1. On the new server, create the directory /usr/local/mgr5/backup/, if that directory does not exist.
    2. Migrate from the old server to the new one in the directory /usr/local/mgr5/backup/:

      We recommend saving custom XML files, addons and plugins as a backup in the directory /usr/local/mgr5/backup/. This will help to identify the causes of the malfunction if there are malfunctions after the migration.
      • /usr/local/mgr5/etc/xml/ — directory with custom XML files;
        scp -r /usr/local/mgr5/etc/xml/ root@<new_server_IP>:/usr/local/mgr5/backup/
      • /usr/local/mgr5/addon/ — directory with custom addons;
        scp -r /usr/local/mgr5/addon/ root@<new_server_IP>:/usr/local/mgr5/backup/
      • /usr/local/mgr5/src/ — directory with custom plugins; 
        scp -r /usr/local/mgr5/src/ root@<new_server_IP>:/usr/local/mgr5/backup/
      • /usr/local/mgr5/skins/userdata/ — directory with custom icons. 
        scp -r /usr/local/mgr5/skins/userdata/ root@<new_server_IP>:/usr/local/mgr5/backup/
    3. Copy the contents of the directories with existing files omitted:

      cp -n /usr/local/mgr5/backup/xml/* /usr/local/mgr5/etc/xml/
      cp -n /usr/local/mgr5/backup/addon/* /usr/local/mgr5/addon/
      cp -n /usr/local/mgr5/backup/src/* /usr/local/mgr5/src/
    4. Re-build and install the required plugins. Read more in Lower-level interaction, C++ plug-ins.

    Step 4. Migrate storefront files

    To move the storefront from the old server to the new server, copy the directories to the new server:

    • /usr/local/mgr5/skins/showroom/ — provider's storefront files;

      scp -r /usr/local/mgr5/skins/showroom/ root@<IP-address_of_new_server>:/usr/local/mgr5/skins/showroom/
    • /usr/local/mgr5/etc/showroom.sample.dragon/ — template files on teh basis of which storefronts are created.

      scp -r /usr/local/mgr5/etc/showroom.sample.dragon/ root@<IP-address_of_new_server>:/usr/local/mgr5/etc/showroom.sample.dragon/

    Step 5. Run the installation of the missing packages

    After migrating the database, run the installation of all missing service processig  module packages, payment systems, and mail gateways on the new server.

    To install the missing packages, run:

    /usr/local/mgr5/sbin/mgrctl -m billmgr fix.modules

    If not all modules are installed after running the command, install them manually.

    Step 6. Bind a commercial license to the new server

    1. After migrating BILLmanager to the new server, enter your client area, where your license was ordered.
    2. Delete the trial license from your client area.
    3. In the commercial license settings, enter the IP address of the new server. Read more in Types of licences.
    4. Update the license file: To do this, enter the BILLmanager web interface, open the section HelpAbout program and click Update license. Or download the license manually with the command:

      /usr/local/mgr5/sbin/licctl fetch billmgr

    Step 7. Disable maintenance mode

    To disable maintenance mode, delete the file /usr/local/mgr5/etc/billmgr.DoNothing.