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, the below scenario may also be seen in a few environments:

During the upgrade of NSX Manager, an error message is displayed stating that NAPP needs to be upgraded first, even though NAPP is not installed in the environment. This issue prevents the upgrade process from proceeding.

 

Error message observed under "Edges" Pre-check:

Check for NSX Application Platform version for upgrade: [Failed to execute Check for NSX Application Platform version for upgrade. [UC] Error in rest call. url= /napp/api/v1/platform/monitor/platform/status , method= GET , response= Unknown Error occurred , error= I/O error on GET request for "https://10.x.y.83:443/napp/api/v1/platform/monitor/platform/status": Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty; nested exception is javax.net.ssl.SSLException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty .]: 

This can be observed when upgrading from and to any version of NSX with Legacy NSX Intelligence Appliance (VM-based) present in the environment.

The root cause of the issue is that the NSX Manager is still trying to check the status of the Intelligence Feature, which might be no longer used, and is causing the upgrade process to fail.

The presence of the legacy NSX Intelligence Appliance (VM-based) is triggering this behavior.

If the environment has a working NSX Intelligence VM-based appliance, it is recommended to have it migrated to the NSX Application Platform based vertical. More information about this can be found in the below document.

https://docs.vmware.com/en/VMware-NSX-Intelligence/4.0/install-upgrade_nsx_intelligence40.pdf

To resolve this specific issue, delete the NSX Intelligence Appliance from the Appliances tab in the NSX Manager that is no longer in use. Once the appliance is deleted, the pre-checks should succeed, and the upgrade process can proceed.