Support Support Downloads Knowledge Base Case Manager My Juniper Community

Knowledge Base

Search our Knowledge Base sites to find answers to your questions.

Ask All Knowledge Base Sites All Knowledge Base Sites JunosE Defect (KA)Knowledge BaseSecurity AdvisoriesTechnical BulletinsTechnotes Sign in to display secure content and recently viewed articles

[Contrail] Package Version Mismatch Alarm

0

0

Article ID: KB35216 KB Last Updated: 21 Nov 2019Version: 2.0
Summary:

This article provides brief information about the package version mismatch alarm in Contrail and how to troubleshoot it.

Symptoms:

In this article, we simulate the package version mismatch alarm by renaming the /usr/bin/contrail-version file and making sure that the contrail-version command is not available on one vrouter.

$ mv /usr/bin/contrail-version /usr/bin/contrail-version.bak
$ contrail-version
-bash: /usr/bin/contrail-version: No such file or directory

Now when we try to get vrouter UVE on the analytics node by using the curl command, we will see that the installed packet version information changed from a valid version, say 3.2.8, to "package-version-unknown" as shown below:

# curl -H "X-Auth-Token:<token>" http://localhost:8081/analytics/uves/vrouter/<hostname>?flat | python -m json.tool | less
<snipped>
    "NodeStatus": {
        "__T": 1571776982196304,
        "all_core_file_list": [
            "oldcrashes"
        ],
        "build_info": "{\"build-info\" : [{\"build-version\" : \"3.2.8.0\", \"build-time\" : \"2017-12-21 11:07:58.264428\", \"build-user\" : \"contrail-builder\", \"build-hostname\" : \"ubuntu\", \"build-id\" : \"3.2.8.0-66\", \"build-number\" : \"66\"}]}",
        "deleted": false,
        "disk_usage_info": {
            "/dev/mapper/bcomp80--vg-root": {
                "partition_space_available_1k": 233592828,
                "partition_space_used_1k": 481683508,
                "partition_type": "ext4",
                "percentage_partition_space_used": 67
            }
        },
        "installed_package_version": "package-version-unknown",
<snipped>

The same alarm is also displayed on the Contrail UI as shown in the following screenshot:

Cause:

The package version mismatch alarm is generated when the installed package version is different from the running packet version. The definition of this alarm can be found in the config database, and the rules can be obtained with the curl command.

# curl -u <user>:<password> http://localhost:8095/alarm/<uuid> | python -mjson.tool 
<snipped>
{
    "alarm": {
        "alarm_rules": {
            "or_list": [
                {
                    "and_list": [
                        {
                            "operand1": "NodeStatus.running_package_version",
                            "operand2": {
                                "uve_attribute": "NodeStatus.installed_package_version"
                            },
                            "operation": "!="
                        }
                    ]
                }
            ]
        },
        "alarm_severity": 0,
        "display_name": "system-defined-package-version-mismatch",
        "fq_name": [
            "default-global-system-config",
            "system-defined-package-version-mismatch"
        ],
<snipped>
        "name": "system-defined-package-version-mismatch",
        "parent_type": "global-system-config",
<snipped>
        "uve_keys": {
            "uve_key": [
                "analytics-node",
                "config-node",
                "control-node",
                "database-node",
                "vrouter"
            ]
        }
    }
}


The installed package version is retrieved by the Contrail node by using the contrail-version command through nodemgr utils lib periodically. This version information is then put into UVE to be sent to the analytics node. If the analytics node finds that the retrieved value is not the same as the running version, a package version mismatch alarm is generated. When you check this alarm, you can see (shown above) that it compares two operands "NodeStatus.running_package_version" and "NodeStatus.installed_package_version."

You can also find a default object created for this alarm with the name "system-defined-package-version-mismatch" on any config nodes.

The alarm is available for the config node, control node, analytics node, database node and vrouter.

Solution:

When you see this alarm, check the Contrail version on the Command Line Interface (CLI) by using contrail-version -d.

  • If the command works, compare the Contrail versions and correct the package version difference by reprovisioning the node in error status.

  • If the command fails, this could be a false alarm. You can then troubleshoot why the command is not working by contacting Support for assistance if needed.

Modification History:

2019-11-21: Article re-organized for clarity; formatting changes done

Comment on this article > Affected Products Browse the Knowledge Base for more articles related to these product categories. Select a category to begin.

Getting Up and Running with Junos

Getting Up and Running with Junos Security Alerts and Vulnerabilities Product Alerts and Software Release Notices Problem Report (PR) Search Tool EOL Notices and Bulletins JTAC User Guide Customer Care User Guide Pathfinder SRX High Availability Configurator SRX VPN Configurator Training Courses and Videos End User Licence Agreement Global Search