QMetry Upgrade Document for RHEL8 & Podman (v8.16.0.1)

QTM (1).png

Note: If you are upgrading to QTM v8.16.0.1, you need to update the Single Sign On (SSO) login URL. Go to https://qmetrysupport.atlassian.net/wiki/spaces/QTMSv816/pages/3571024060 and refer to the corresponding Identity Provider page to know the URL changes.

In this guide, we will run you through upgrading to QMetry Test Management v8.16.0.1 from any previous version. These steps should be followed on your QMetry app server hosted on the RHEL 8 machine.

Pre-requisites

Important Prerequisites to check before the upgrade.

  • Mysql version of QMetry Reports and QMetry Application should be 8.0.33.

  • Ensure internet connectivity is enabled on the server for this upgrade.

Step 1: IMPORTANT: Backup your existing QMetry Database

Take the backup of your existing “qmetry” database. You can replace the username, password, and location of the backup file (currently default /opt).

  • Syntax : podman exec qmetryapp_db sh -c 'exec mysqldump -uroot -p<password> --triggers --routines --hex-blob --single-transaction --lock-tables --no-create-db qmetry' > /opt/qmetry_backup_<date>.sql

  • For example: podman exec qmetryapp_db sh -c 'exec mysqldump -uroot -pqmetry --triggers --routines --hex-blob --single-transaction --lock-tables --no-create-db qmetry' > /opt/qmetry_backup_2021-01-01.sql

Verify that your database has been backed up properly and is available for later use in case of any emergency.

Step 2: Download Required Files

  • You can generate a request on the QMetry Support Portal, to get the latest version of QMetry Upgrade Installer.

  • Download the UpgradeQMetryApp.zip to your QMetry Application Server on host machine once you receive it.

Step 3: Run the QMetry Upgrade

1. Check the running containers using the following command. The podman must be running to ensure a successful upgrade.

  • podman ps

  • If the podman is not running, start it using the below commands (replace container names according to the application container name seen in the command above)

    • podman start qmetryapp_db

    • podman start qmetry_app_1

2. Go to the directory where the UpgradeQMetryApp.zip file is downloaded.

3. Unzip the file UpgradeQMetryApp.zip on the host machine. 

  • unzip UpgradeQMetryApp.zip

4. Go to QMetry directory:

  • cd UpgradeQMetryApp

5. Give permission to upgrade_81601.sh file through the following command.

  • chmod +x upgrade_81601.sh


Note: If the existing QMetry version is below 8.9.0.3, then make sure to validate the name of an existing container and license volume in upgrade_81601.sh file before running it.

Steps to validate the name of an existing container and license volume:

(i) Check podman volumes name using the below command.

  • podman volume ls

(ii) podman volume name should be qmetry_license.

(iii) Check podman container name using the below command.

  • podman ps

(iv) Podman container name should be qmetry_app_1. 

(v) If any of these names are not the same as above, then update upgrade_81601.sh file for the changed value with the respective names using the following steps.

  • Open the file – upgrade_81601.sh in edit mode.

    • vi upgrade_81601.sh

    • Update the file for the changed value with the respective names of the volume and container.

    • Press i to change the file mode to insert.

    • Update the variable value according to the existing docker volume and docker container name.

      • exist_license_volume → Value from podman volume ls for license 

      • exist_qmetry_container → Value from podman ps for qmetry

    • Press Esc, and then type :wq to save the changes. 

6. Execute this command.

  • sh upgrade_81601.sh 

Wait for the process to complete.

Step 4: Check QMetry and MySQL Container

  • Check the running containers using the following command:

    • podman ps

 

Note: If you are upgrading the QTM app to version 8.16.0.1, it is essential to update the Automation API to the latest version. Refer to https://qmetrysupport.atlassian.net/wiki/spaces/QTMSv816/pages/3541045327.