NSX Upgrade fails during pre-check stage due to failure in getting NAPP version
search cancel

NSX Upgrade fails during pre-check stage due to failure in getting NAPP version

book

Article ID: 373441

calendar_today

Updated On:

Products

VMware vDefend Firewall VMware vDefend Firewall with Advanced Threat Prevention

Issue/Introduction

If NAPP has been upgraded to 4.2.0, and NSX is upgraded later (like a week later), NSX upgrade can fail during the Pre-Check (Edge and Host pre-check) stage with below error message:
Similar error message is seen on the vCenter when the Pre-Check is run via vLCM

"Failed to execute Check for NSX Application Platform version for upgrade."

The NSX Upgrade UI will show the following screen

Clicking on the error will shows the error detail

Environment

NAPP 4.2.0

Cause

NAPP version is stored in an internal cache during startup. This version should remain persistent until NAPP is upgraded.  However, the upgrade pre-check fails to validate the version due to it missing in the cache. The cache had gotten cleaned up erroneously due to a cron job that runs once a week. 

This impacts only NSX upgrade operation if NAPP 4.2.0 is installed and upgrade is attempted at least a week after NAPP startup. The version will not be shown in the NAPP UI once the cache has been cleared, but there is no operational impact.

Resolution

Prior to NSX Upgrade or after the upgrade pre-check fails, run the following commands. 

Step 1:  Login to NSX Manager via SSH using root account

Step 2:  Edit monitor configmap file and change clearCacheIntervalSeconds value to 31449600.

napp-k edit configmap monitor-application-config -n nsxi-platform

          - change the clearCacheIntervalSeconds value to 31449600

          - save the file using ":wq"

Step 3: Restart Monitor pod which will reinitialize the cache. 

napp-k rollout restart deployment monitor -n nsxi-platform

Step 4: Do the NSX upgrade.

Additional Information

VMware by Broadcom will address this issue in the next NAPP release.

Additionally, you may encounter the error when Legacy NSX Intelligence Appliance (VM-based) are present in the environment. In that case follow the steps on kb:

NSX Upgrade Pre-check fails with the error message "Failed to execute Check for NSX Application Platform version for upgrade."