Cisco Nexus Dashboard Orchestrator Deployment Guide, Release 4.2(x)

PDF

Validate Existing Configuration

Want to summarize with AI?

Log in

Overview

sd Validate Existing Configuration

Note

If you are upgrading from release 4.0(1) or later, you can skip this section and proceed to Upgrade Your Nexus Dashboard Cluster.

As mentioned in the Overview, release 4.0(1) introduced a number of template validations and enforces a set of best practices when it comes to template design and deployment. The upgrade process automatically verifies the existing templates and updates them as necessary. However, some template issues cannot be addressed automatically by the upgrade and you must resolve them before upgrading from a release prior to release 4.0(1).

This section describes how to validate your existing configuration before proceeding with the upgrade.

Before you begin

You must have the following completed:

Procedure

1.

Download and verify the configuration validation script.

You will use this script to validate your existing configuration before creating a backup and upgrading the Orchestrator service to this release.

  1. Ensure that you have Python installed on your local machine.

    The script requires Python 3 to run. You can check if Python is installed on your machine using the following command:

    $ python3 --version
    Python 3.9.6
  2. Download and extract the validation script tarball.

    Navigate to https://software.cisco.com/download/home/285968390/type/286317465, select the target NDO version to which you want to upgrade, download the upgrade validation script ( Final_ndo<version>-UpgradeValidationScript.tgz), then extract it, for example:
    $ tar -xzf Final_ndo<version>-UpgradeValidationScript.tgz
    $ ls
    ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM
    Final_ndo4.1.2h-UpgradeValidationScript.tgz
    UpgradeValidationScript.tgz
    UpgradeValidationScript.tgz.signature
    cisco_x509_verify_release.py3
  3. Verify the validation script tarball signature.

    You can use the following command to verify the Cisco signature on the configuration validation script.

    $ ./cisco_x509_verify_release.py3 -e ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM \
      -i UpgradeValidationScript.tgz -s UpgradeValidationScript.tgz.signature -v dgst -sha512
    Retrieving CA certificate from https://www.cisco.com/security/pki/certs/crcam2.cer ...
    Successfully retrieved and verified crcam2.cer.
    Retrieving SubCA certificate from https://www.cisco.com/security/pki/certs/innerspace.cer ...
    Successfully retrieved and verified innerspace.cer.
    Successfully verified root, subca and end-entity certificate chain.
    Successfully fetched a public key from ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM.
    Successfully verified the signature of UpgradeValidationScript.tgz using ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM
    Note

    If signature verification fails, you will receive the following error:

    $ ./cisco_x509_verify_release.py3 -e ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM\
    -i UpgradeValidationScript.tgz -s UpgradeValidationScript.tgz.signature.fail -v dgst -sha512
    Retrieving CA certificate from https://www.cisco.com/security/pki/certs/crcam2.cer ...
    Successfully retrieved and verified crcam2.cer.
    Retrieving SubCA certificate from https://www.cisco.com/security/pki/certs/innerspace.cer ...
    Successfully retrieved and verified innerspace.cer.
    Successfully verified root, subca and end-entity certificate chain.
    Successfully fetched a public key from ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM.
    Error log: Failed to verify dgst signature of UpgradeValidationScript.tgz.
    Error log: Verification Failure

    In this case, we recommend you re-download the <ndo-version>-UpgradeValidationScript.tgz tarball from the Cisco Software Download portal.

  4. Once the validation script signature is verified, extract the script itself.

    % tar -xzf UpgradeValidationScript.tgz
    $ ls
    ACI_4070389ff0d61fc7fbb8cdfdec0f38f30482c22e.PEM
    Final_ndo4.1.2h-UpgradeValidationScript.tgz
    README.md
    UpgradeValidationScript.tgz
    UpgradeValidationScript.tgz.signature
    cisco_x509_verify_release.py3
    ndo
    ndoCmd.py
    ndoCopy.py
    requirements.txt
2.

Validate your existing configuration before you create the backup.

You can verify that your configuration backup will be compatible with upgrade to this release by running the validation script you have downloaded in the previous step. If for any reason you are unable to run the script, we recommend contacting Cisco support to have them validate your configuration backup before proceeding with the upgrade.

  1. Log in to your Nexus Dashboard and open the Nexus Dashboard Orchestrator service.

  2. Download the tech support logs from your existing Orchestrator.

    While for the migration you will create and download the configuration backup using the standard procedure, the validation is done on the tech support information. Note that it is normal for the tech support archive to be significantly larger than your typical configuration backup.

    You can generate the tech support logs by navigating to Admin > Tech Support page in the Orchestrator UI. Then click the Download icon in the System Logs tile. This downloads the msc_report_<date>.zip archive to your machine.

  3. Extract the tech support archive you downloaded.

    The tech support archive comes in a standard .zip format, so you can use any tool of your choice to extract the contents, for example:

    $ unzip msc_report_<date>.zip

    After you extract the archive, copy the msc-db-json-<date>_temp.tar.gz file inside into the directory where you extracted the validation script.

  4. Run the validation script.

    The script requires a number of dependencies, which are all defined in the requirements.txt file that comes with the script, so we recommend creating a Python virtual environment before installing the dependencies and running the script:

    $ python -m venv ndo-upgrade
    $ source ndo-upgrade/bin/activate
    $ pip install -r requirements.txt

    After the virtual environment is set up and the required modules are installed, run the script using the tech support file you downloaded and extracted in a previous step, for example:

    • -f allows you to provide the file on which to run the validation.

    • -N specifies that no configuration will be deployed to any live system.

    • -C generates the JSON-formatted output at the end of the script.

    (ndo-upgrade)ndoCmd $ ./ndoCopy.py -f msc_report_20220617_181529/msc-db-json-20220617181553_temp.tar.gz -N -C
    11:49:56 Loading collection site2...4
    11:49:56 Loading collection tenant...12
    [...]
    11:49:56 Checking template versions
    11:49:56 Checking policy deployment dependencies
    11:49:56 Fixing template policy flow loops
    11:49:56 Fixing template dependency loops
    11:49:56 Fixing policies for upgrade
    11:49:56 Determine template ordering
    11:49:56 Analysis completed
    {
      "summaryStats": {
        "appTemplatePoliciesConverted": 139,
        "appTemplateSiteAssocMods": 7,
        "appTemplatePolicyEvictions": 2,
        "appTemplateSchemasConverted": 11,
        "appTemplatesConverted": 38,
        "appTemplatesCreated": 1,
        "tenantMods": 1
      },
    [...]
    }

    After the output is generated:

    • If there are no errors or warnings blocks at the end of the generated JSON, then your configuration is compliant with the migration requirements and you can proceed to the "Back up existing deployment configuration" step.

    • If there is only a number of warnings but no errors, it means the migration will complete successfully, but there's a number of things that you may want to resolve before or after the upgrade. We recommend reviewing any warnings before continuing with the next step.

        "warnings": [
          "dropped DHCP Relay policy dhcp-tn-epgOnRL-policy: invalid provider ip address: 141.1.141.2/24",
          "dropped Route Map policy sameContract: fromPrefixLen and toPrefixLen must be larger than prefix",
          "dropped Mulicast Route Map policy mCastRt.map: invalid RP ip: 12.13.14.15/23",
          "dropped DHCP Option policy dhcpBdMso-option: duplicate option id: 1; duplicate option id: 1",
          "removed dhcpLabels.0 from bd[tn-epgOnRL::Template 1::bdDhcpClient] for 
      unresolved policy ref key[dhcpRelayPolicies::tn-epgOnRL::dhcp-tn-epgOnRL-policy]",
          "removed dhcpLabels.0 from bd[dhcp-msite-mso::bd::bd-client-l3out] for 
      unresolved policy ref key[dhcpRelayPolicies::dhcp-msite-mso::dhcp-msite-mso-relay-policy-epg-cleint-l3out]"
        ], 
    • If there is 1 or more errors listed in the JSON, the migration would fail if you continue with the current configuration.

      Note

      You must resolve any existing errors before creating the backup and proceeding with the upgrade. We recommend re-running the validation script after you resolve any existing errors to ensure that the backup will be ready for the migration.

      For example, the following sample shows 2 possible errors that can come up during validation:

      "errors": [
        "template appTemplate[<template>] version 6 is in state EDIT_CONFIG",
        "deployed policy bd[<bd>] requires vrf[<vrf>] which is not deployed",
      ] 
      • As mentioned in the Prerequisites and Guidelines section, any deployed templates must not have undeployed changes. You must either deploy the latest version of that template or revert to the deployed version (so it is the latest version) and re-deploy the template.

      • Objects must be deployed in order of their dependencies. In other words, you must not have a deployed bridge domain if the required VRF is not deployed.

  5. Resolve any shown errors and repeat this step to re-validate the configuration.