ptp no-lock alarm raised incorrectly when clock instance configured without ts2phc

Bug #1998132 reported by Cole Walker
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Low
Cole Walker

Bug Description

Brief Description
-----------------
When a node is configured with a clock type ptp instance but no ts2phc instance, collectd raises a no-lock alarm. This alarm is not applicable to the clock type and is misleading.

Severity
--------
<Minor: System/Feature is usable with minor issue>

Steps to Reproduce
------------------
Configure a ptp-instance of type clock and apply the configuration. When there is no ts2phc instance on the system, a ptp-no lock alarm is raised.

Expected Behavior
------------------
ptp no-lock alarm should not be present

Actual Behavior
----------------
Alarm is raised

Reproducibility
---------------
100%

System Configuration
--------------------
Any

Branch/Pull Time/Commit
-----------------------
Stx master

Last Pass
---------
N/A

Timestamp/Logs
--------------
Attach the logs for debugging (use attachments in Launchpad or for large collect files use: https://files.starlingx.kube.cengn.ca/)
Provide a snippet of logs here and the timestamp when issue was seen.
Please indicate the unique identifier in the logs to highlight the problem

Test Activity
-------------
Developer testing

Workaround
----------
None

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to monitoring (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/monitoring/+/865911

Changed in starlingx:
status: New → In Progress
Cole Walker (cwalops)
Changed in starlingx:
assignee: nobody → Cole Walker (cwalops)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to monitoring (master)

Reviewed: https://review.opendev.org/c/starlingx/monitoring/+/865911
Committed: https://opendev.org/starlingx/monitoring/commit/4efcb548dbe7257a5ad22fc1903c555fc47f3a6b
Submitter: "Zuul (22348)"
Branch: master

commit 4efcb548dbe7257a5ad22fc1903c555fc47f3a6b
Author: Cole Walker <email address hidden>
Date: Mon Nov 28 15:44:21 2022 -0500

    [PTP] Skip checking clock instance for ptp-lock

    When no ts2phc instance is configured on a node, collectd incorrectly
    tries to check 'clock' type instances for a PTP lock state. The 'clock'
    instance type does not contain ptp4l configuration info and should not
    be part of this check. This was resulting in an incorrect 'ptp no-lock'
    alarm being raised.

    Updated the logic for calling check_ptp_regular() so that 'clock'
    instances are excluded.

    Test plan:
    PASS: Configure system with clock instance and no ts2phc instance,
    verify alarm is not raised.
    PASS: Configure system with clock and ts2phc instances and verify that
    normal behaviour is unaffected.

    Closes-bug: 1998132

    Signed-off-by: Cole Walker <email address hidden>
    Change-Id: Id3941ed2079478e9c1241cf613d3fa3486e653c0

Changed in starlingx:
status: In Progress → Fix Released
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → Low
tags: added: stx.8.0 stx.apps stx.networking
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.