How to Monitor M-series Appliance Firmware Upgrades |
General Upgrade Concepts:
Components of a Firmware Upgrade:
You can become more familar with how upgrades work by extracting and reading the scripts that come bundled in the .fw files used to upgrade the appliance from the GUI or service.sh script (used to upgrade Gateway appliances). To learn how to extract these files see the Extracting files from .fw images section of the useful notes for support page linked to the article.
Here are a lists of the scirpts extracted from .fw upgrade files, here I'm using the 5.3 code version. These have been broken down into directories representing the fiels extracted from each fw image.
[root@downm440 5.3]# ls ./fw1 | grep .sh
CommonFunctions.sh
ExtractParts.sh
UpgradeBase.sh
VerifyAPIVersion.sh
VersionCheck.sh
[root@downm440 5.3]# ls ./fw2 | grep .sh
ExtractParts.sh
UpgradeBase.sh
VerifyAPIVersion.sh
VersionCheck.sh
As you can see most of the scripts are identical, however the first image of the contains an additional script, CommonFunctions.sh.
[root@downm440 5.3]# diff ./fw1/ExtractParts.sh ./fw2/ExtractParts.sh
[root@downm440 5.3]# diff ./fw1/UpgradeBase.sh ./fw2/UpgradeBase.sh
[root@downm440 5.3]# diff ./fw1/VerifyAPIVersion.sh ./fw2/VerifyAPIVersion.sh
[root@downm440 5.3]# diff ./fw1/VersionCheck.sh ./fw2/VersionCheck.sh
Scripts Functions and roles:
- CommonFunctions.sh
The first part of this script sets some variable that are used by internal functions, most notable the strings used to update the checkpoint file and some path variable for the seer. The functions in this script update the /var/log/DXi/upgrades/checkpoint file and handle service ticket and admin alert reporting related to upgrades.
- ExtractParts.sh
Script for extracting and verifying the .fw parts. During this process there is a function to update /var/log/DXi/upgrade/Node1.upgradeoutput.log
- UpgradeBase.sh
Responsible for upgrading the following:
function InstallGatewayClient ()
function InstallGatewayAgent ()
function InstallStornext()
function InstallSNAPI()
function InstallRPMs()
Also logs to /var/log/DXi/upgrade/Node1.upgradeoutput.log and /var/DXi/base-upgrade-in-progress.
- VerifyAPIVersion.sh
Script for comparing the StorNext GUI API version with the platform API version to ensure they match. Also logs to /var/log/DXi/upgrade/Node1.upgradeoutput.log.
-VersionCheck.sh
Responsible for checking the following files extract from the .fw files against linux regular files on the system. This can be called from the GUI, discussed later in the Firmware Upgrade Flow section.
#Showing variables from the script to show directories we check.
INS_BASE=/opt/DXi/base_version
INS_APPS=/opt/DXi/version_info
UPG_BASE=./base-version_info
UPG_APPS=./version_info
UPG_TABLE=./VersionTable.conf
#Running the check here, the script does log to the /var/log/DXi/upgrade/Node1.upgradeoutput.log file.
./vc --base $INS_BASE \
--apps $INS_APPS \
--upg-base $UPG_BASE \
--upg-apps $UPG_APPS.$Series \
--table $UPG_TABLE.$Series \
$VERBOSE >> $LOGFILE 2>&1
The script can be bypassed by the following touch file.
# backdoor to skip version check all together
/var/DXi/skip-version-check
-rpmUpgradeVerCheck.py
This script performs RPM version checking to evaluate whether a given RPM needs to be installed
It takes the rpm filename (xxxx.rpm) as its argument
It returns 3 exit codes:
0 - The package is already installed with the same version
1 - The existing package needs to be upgraded to the specified package or the package is not installed
2 - The existing package is newer than the specified package
-Upgrade.DXiSNA.<Model>
Main script that does the upgrade itself. Responsible for checking array firmware levels, maintaining the upgrade script run levels, doing RPM installation, and the Post Install Scripts.
-VersionTable.conf.<Model> file
Used by the VersionCheck.sh script.
-version_info.<Model> fIle
Used by the VersionCheck.sh script.
Linked Pages:
Useful Notes For Support during firmware upgrades
This page was generated by the BrainKeeper Enterprise Wiki, © 2018 |