-
Notifications
You must be signed in to change notification settings - Fork 387
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[IOS-XE] "show ntp assocations" parser does not correctly summarize clock state #899
Comments
Hi, I have reproduced the issue. Kindly give me some time to debug and fix it. Thank you. |
case 1: if we consider the output:
If the line executes, the "clock_state" parameter is overridden, but other values remain unchanged(i.e associations_address, associations_local_mode, clock_offset, etc), resulting in "clock_state": "unsynchronized". other details as well as the clock state need to remain unchanged in this case. Is this behavior correct? case 2: Now, if we consider the output:
In this case, if the first line executes
it will mark "clock_state": "unsynchronized", and it will capture candidate (+) related data like associations_address = 192.0.2.10 , associations_local_mode, clock_offset, etc. When the next line |
Hi @Harishv01, Case 1's behavior is incorrect and is the root cause of this bug. Simply put, if any NTP peer has an asterisk, then the overall system's clock state should be marked as synchronized. |
Hi @ChristopherJHart, I have raised the PR, and the expected output looks like below. Please let me know if everything looks good or not. Thank you!
|
This looks good - thank you! |
Hi, we have merged the PR and the fix will be available in the next version, i.e pyats 24.10. Hence, I am closing the issue. Thank you! |
The value of the
clock_state.system_status.clock_state
key in the IOS-XEshow ntp associations
has an incorrect value with some permutations of output.For example, with the below output:
Results in the below parsed data:
We can see that the value of the
clock_state.system_status.clock_state
indicates the device is unsychronized, even though it's synchronized.The text was updated successfully, but these errors were encountered: