Upgrading Local Edition Cluster from 5.5.0 to 5.5.1 for Kubernetes in Untethered mode

The following section provides information on upgrading Local Edition cluster from version 5.5.0 to 5.5.1 for Kubernetes in untethered mode.

Prerequisites

  • Local Edition 5.5.1 images must be built and pushed to the desired registry for deployment.
  • The volumes for tml-nosql, tml-logtml-cacheare reused, so while doing upgrade the number of these pods must be consistent with the earlier version.
  • The customization done to the JSON properties files at docker-deploy/properties/*.json in earlier version must be ported to 5.5.1.
  • Admin must generate the manifest deployment folder, namely the manifest-single-zone, as per the deployment topology for version 5.5.1 by running the compose command.
Note:
  • The following procedure is applicable for single and multi zone clusters.
  • 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.5.0 NoSQL container. Run the following command.
      • For single-zone deployment:
        ./undeploy-nosql-pod.sh
    2. Deploy Local Edition 5.5.1 NoSQL containers. Run the following command.
      • For single-zone deployment:
        ./deploy-nosql-pod.sh
  2. Undeploy and redeploy Log components.
    1. To remove running Local Edition 5.5.0 Log container, run the following command.
      • For single-zone deployment:
        ./undeploy-log-pod.sh
    2. To deploy Local Edition 5.5.1 Log containers for single-zone deployment, run the following command.
      ./deploy-log-pod.sh
  3. Undeploy and redeploy CM components.
    1. To remove running Local Edition 5.5.0 CM container, run the following command.
      ./undeploy-cm-pod.sh
    2. To deploy Local Edition 5.5.1 CM containers, run the following command.
      ./deploy-cm-pod.sh
  4. Undeploy and redeploy SQL components.
    1. Dump MySQL Data from the cluster created in the earlier version. Login to any tml-sql pod running in the earlier cluster.
      kubectl exec -it mysql-set-0-0 -- /bin/bash
      
    2. To dump MySQL data, run the following command. Update the MySQL password for the cluster.
      mysqldump --no-create-info --complete-insert --single-transaction -u root -p'changeme' --ignore-table=masherysolar.area_config --ignore-table=masherysolar.areas --ignore-table=masherysolar.package_key_audit_log --ignore-table=masherysolar.application_audit_log --set-gtid-purged=OFF masherysolar > /tmp/mash_data.sql
      Note: In case duplication of data occurs then redo the MySQL data dump by ignoring the duplicate entries. The following are few cases where duplication of entries is observed.
      • masherysolar.member_activity_log
      • masherysolar.member_audit_log
      • masherysolar.member_role_audit_log
      • masherysolar.method_override_audit_log
      • masherysolar.migration_log
    3. Copy the MySQL data file to the host.
      kubectl cp mysql-set-0-0:/tmp/mash_data.sql mash_data.sql
      1. Remove the SQL container from the 5.5.0 cluster.

        For single zone deployment,

        ./undeploy-sql-pod.sh
      2. Delete SQL pvc after undeploying the SQL pod.
        kubectl delete pvc $(kubectl get pvc -o=jsonpath='{.items[?(@.metadata.labels.app=="mysql-svc")].metadata.name}')l
      3. Deploy Local Edition 5.5.1 SQL containers. Run the following command.

        For single zone deployment:

        ./deploy-sql-pod.sh
    4. Copy the MySQL data from 5.5.0 cluster in the 5.5.1 cluster.
      Run the following command to copy MySQL data file to any tml-sql pod in TML 5.5.0 cluster
      kubectl cp mash_data.sql mysql-set-0-0:/tmp
    5. Clear the MySQL data in the 5.5.0 cluster.
      1. In the 5.5.0 cluster, login to thetml-sql pod where the MySQL data file was copied.
        kubectl exec -it mysql-set-0-0 -- /bin/bash
      2. To clear data in MySQL:
        mysql -u root -p'changeme' -Nse 'show tables' masherysolar | sed -r 's/\b(area_config|areas|package_key_audit_log)\b//g' | sed '/^$/d' | while read table; do mysql -u root -p'changeme' -e "truncate table $table" masherysolar; done
    6. Import MySQL data dumped from the 5.5.0 cluster to the 5.5.1 cluster.
      Run the following command in each tml-sql pod in the new cluster.
      mysql -u root -p'changeme' masherysolar < /tmp/mash_data.sql
  5. Undeploy and redeploy Cache components.
    Remove running Local Edition 5.5.0 Cache container.
    1. For single zone undeployment:
      ./undeploy-cache-pod.sh
    2. To deploy the Local Edition 5.5.1 Cache container, run the following command.
      ./deploy-cache-pod.sh
  6. Undeploy and redeploy TM components.
    Remove running Local Edition 5.5.0 TM container.
    1. For single zone undeployment:
      ./undeploy-tm-pod.sh
    2. To deploy Local Edition 5.5.1 TM container, run the following command.
      ./deploy-tm-pod.sh
  7. Optional. This step is applicable if reporting pod is deployed. Undeploy and redeploy Reporting components.
    Remove running Local Edition 5.5.0 TM container.
    1. For single zone undeployment:
      ./undeploy-reporting-pod.sh
    2. To deploy 5.5.1 TM container, run the following command.
      ./deploy-reporting-pod.sh