MGR Upgrade MOP
Introduction
This guide provides steps to upgrade the MGR to fix Intermittent Database Error: DBD::mysql::db DESTROY failed: MySQL server has gone away.
Why Upgrade?
- New Features and Enhancements: Fix the intermittent Database Error: DBD::mysql::db DESTROY failed: MySQL server has gone away when user views the Statistics --> System --> Overview screen on first login.
Intended Audience: This guide is intended for system administrators.
Assumptions:
- You have administrative access to the system where all Lithium elements are installed.
- You have access to the upgrade package/installer.
Pre-Upgrade Checklist and Preparations
Before proceeding with the upgrade, ensure the following steps are completed:
Verify System Requirements
- Action: Confirm that your system meets the minimum and recommended requirements for the new version.
- Steps:
- SSH into each server node.
- Check the output of command
cat /etc/redhat-release - Ensure the output is Red Hat Enterprise Linux Server release 8.10 (Ootpa)
Review Release Versions
- Action: Carefully note down current versions of impact components in your system. Review the change logs from current versions to the target versions.
- Steps:
- SSH to each server, exam and note down the current installed version via command:
rpm -qa TextPassMGR
- Note down the following target component and versions:
- TextPassMGR: R04.24.03.06
Download the Upgrade ISO
- Action: Download the official SW iso for the target version from the trust source. Expect the iso file name:
- NMM-SW-24.03.20-RHEL8.iso
Backup Your System
- Action: Perform a full backup (or take snapshots) of all server nodes. This is crucial for full rollback if needed. Additionally, take the following backup steps for quick rollback.
- Steps:
- Evaluate the free disk space before proceeding.
Performing the Upgrade
This section outlines the detailed steps to perform the upgrade.
Update yum repository
- Action: Update the yum repository by mounting a new SW ISO file and modifying the repository configuration, you can follow these steps. Ensure you have the necessary permissions and that the ISO file is available on the server or accessible via network share.
- Steps:
- SSH into the server node where the MGR installed.
- Copy the ISO file to the server if it's not already there. You can use
scpor any other file transfer method. - Create a mount point for the ISO
mkdir -p /var/TextPass/Upgrade-iso
- Mount the ISO file to the mount point
mount -o loop <path-SW-iso-file> /var/TextPass/Upgrade-iso
- Update the yum repo file
- Update the
/etc/yum.repos.d/lithium-SW_local.repoas the following:
- Update the
[lithium-SW-repo-Local]
name=Local Repository for Lithium SW packages
# baseurl=file:///var/Packages/SW/
baseurl=file:///var/TextPass/Upgrade-iso/SW/
gpgcheck=0
enabled=1
module_hotfixes=true
- Clear yum cache
yum clean all
- Verify target package versions are available
yum list --showduplicates TextPassMGR
Upgrade TextPassMGR
- Action: Upgrade the TextPassMGR. Execute this step on all nodes where the MGR is installed.
- Steps:
- SSH to each MGR node.
- Execute command
yum update TextPassMGR
- Review the updating package version and press y on prompt
- Start the MGR by the following commands (via root)
/usr/TextPass/bin/tp_mgr_start
Post-Upgrade Verification
After the upgrade, it's crucial to verify that the system is functioning correctly.
Verify MGR startup log
- Action: Ensure MGR server is online without errors.
- Steps:
- SSH to MGR node
- Check the log file
/var/TextPass/MGR/logs/mgr_error_log.*
Verify MGR site
- Action: Ensure MGR site is online
- Steps:
- Open the MGR UI via browser.
- Login with admin user without issue.
- Go to Statistics --> System --> Overview screen, no DB error message.
Functional Testing
- NA
System Monitoring
- Action: Monitor the system after the upgrade to identify any potential issues.
- Steps:
- Observe the Lithium component status across all the node
su - textpass -c tp_status
- Please monitor the
/var/log/messagessystem log file and ensure there are no error messages.
Troubleshooting
NA
Rollback Procedure (If Necessary)
If the upgrade encounters critical issues that cannot be resolved quickly, you may need to rollback to the previous version.
Revert yum repository
- Action: Revert the yum repository setting.
- Steps:
- Revert the
/etc/yum.repos.d/lithium-SW_local.repo- Make sure it is pointing to the default
file:///var/Packages/SW/ - Clean yum cache
yum clean all
- Make sure it is pointing to the default
- (Optional) Umount the iso and delete the NMM-SW-24.03.20-RHEL8.iso
Downgrade
- Action: Downgrade TextPassMGR to the original version.
- Steps:
- SSH to each nodes
yum downgrade TextPassMGR-<version>
- Start MGR
/usr/TextPass/bin/tp_mgr_start
Verify Rollback
- Action: Verify that the previous version is functioning correctly.
- Steps:
- Validate the Lithium components in operating state
su - textpass -c tp_status
- Ensure that any issues caused by the upgrade are resolved.