Upgrading Local Edition cluster from 5.4.1 to 5.5.0 for Docker Swarm Tethered

The following section provides information on upgrading Local Edition cluster from version 5.4.1 to 5.5.0 for Docker swarm.

The following steps are applicable to swarm environment in tethered mode.

Prerequisites

  • Local Edition 5.4.1 images must be built and pushed to the desired registry for deployment.
  • The customization done to the JSON properties files in earlier version must be ported to 5.5.0.
  • Admin must generate the manifest deployment folder, namely the manifest-single-zone, as per the deployment topology for version 5.4.1 by running the compose command.
Note: Some traffic disruptions are expected during upgrade. To minimize disruptions, upgrade theLocal Edition components sequentially, explained as follows.

Procedure

  1. Undeploy and redeploy NoSQL components.
    1. Remove running Local Edition 5.4.1 NoSQL container. Run the following command.
      • For single-zone deployment:
        ./undeploy-nosql-pod.sh
    2. Deploy Local Edition 5.5.0 NoSQL containers. Run the following command.
      • For single-zone deployment:
        ./deploy-nosql-pod.sh
  2. Undeploy and redeploy Log components.
    1. Remove running Local Edition 5.4.1 Log container. Run the following command.
      • For single-zone deployment:
        ./undeploy-log-pod.sh
    2. Update the permissions for restricted user on Log volume. Run the following command on host machine where Log pod is installed.
      chown 1001:1003 -R /var/lib/docker/volumes/logstack_log-1-vol/_data/data/tml-log/
    3. Deploy Local Edition 5.5.0 Log containers. Run the following command.
      • For single-zone deployment:
        ./deploy-log-pod.sh
  3. Undeploy and redeploy CM components.
    1. Remove running Local Edition 5.4.1 CM container. Run the following command.
      • For single-zone deployment:
        ./undeploy-cm-pod.sh
    2. Deploy Local Edition 5.5.0 CM containers. Run the following command.
      • For single-zone deployment:
        ./deploy-cm-pod.sh
  4. Undeploy and redeploy SQL components.

    The MySQL Certificate/Identity data migration for tethered mode works for the following migration cases:

    • 5.3.1 to 5.4.1
    • 5.3.1 to 5.5.0
    • 5.4.1 to 5.5.0

    Please complete the Certificate/Identity data migration as soon as the new cluster is deployed, otherwise new certificates/identities created in the new6 /blop cluster will be overwritten by data migration.

    1. Dump MySQL Data from the cluster created in the earlier version. Login to any tml-sql pod running in the earlier cluster.
      docker exec -it <mysql pod> -- /bin/bash
      
    2. Run the following command to dump MySQL data. Update the MySQL password for the cluster.
      docker exec <sql-container-id> mysqldump --no-create-info --complete-insert --single-transaction -u root -p'changeme' masherysolar trust_store identity_store > mash_data.sql
    3. Copy the MySQL data file to the host.
      docker cp <mysql pod>:/tmp/mash_data.sql mash_data.sql
    4. Remove the SQL container from the 5.4.1 cluster.
      For single zone deployment,
      ./undeploy-sql-pod.sh
      Note: Delete SQL pvc after undeploying the SQL pod,
      docker volume rm sqlstack_sql-1-vol
    5. Deploy Mashery Local 5.5.0 SQL containers. Run the following command.
      For single zone deployment,
      ./deploy-sql-pod.sh
  5. Copy the MySQL data from 5.4.0 cluster in the 5.5.0 cluster.
    Run the following command to copy MySQL data file to any tml-sql pod in TML 5.5.0 cluster
    docker cp mash_data.sql <mysql pod>:/tmp
    Note: The "mysql-set-0-0" is thetml-sql pod in the new cluster.
  6. Import MySQL data dumped from the 5.4.1 cluster to the 5.5.0 cluster.

    Run the following command in each tml-sql pod in the new cluster.

    mysql -u root -p'changeme' -e "truncate table masherysolar.trust_store"
    mysql -u root -p'changeme' -e "truncate table masherysolar.identity_store"
    mysql -u root -p'changeme' masherysolar < /tmp/mash531_data.sql
  7. Run the SQL loader in sql pods in the new TML Cluster.

    Run the following command in eachtml-sql to run the sql loader.

    /opt/sqlloader/onpremloader --service --mapi --devclass --packager --httpsclientsecurity --env production --verbose
  8. Undeploy and redeploy Cache components.
    Remove running Local Edition 5.4.1 Cache container.
    1. For single zone undeployment:
      • ./undeploy-cache-pod.sh
    2. To redeploy the container, run the following command.
      ./deploy-cache-pod.sh
  9. Undeploy and redeploy TM components.
    Remove running Local Edition 5.4.0 TM container.
    1. For single zone undeployment:
      • ./undeploy-tm-pod.sh
    2. Deploy TM container, run the following command.
      ./deploy-tm-pod.sh
  10. Undeploy and redeploy Reporting components.
    Remove running Local Edition 5.4.1 TM container.
    1. For single zone undeployment:
      • ./undeploy-reporting-pod.sh
    2. Update the permissions for restricted user on Reporting volume. Run the following command on Host Machine where Reporting pod installed.
      chown 1001:1003 -R /var/lib/docker/volumes/reportingstack_reporting-1-vol/_data/data/
    3. Deploy 5.5.0 TM container, run the following command.
      ./deploy-reporting-pod.sh