[NXOS] fix: do attempt to delete icmp redirection config on swithport interfaces#229
Draft
[NXOS] fix: do attempt to delete icmp redirection config on swithport interfaces#229
Conversation
21f241a to
fe4444c
Compare
Check if interface is a switchport before attempting to remove its icmp redirect configuration.
fe4444c to
d0d3361
Compare
Merging this branch will not change overall coverage
Coverage by fileChanged files (no unit tests)
Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code. |
| case v1alpha1.InterfaceTypePhysical: | ||
| if err := p.client.Delete(ctx, icmp); err != nil { | ||
| return err | ||
| if req.Interface.Spec.Switchport == nil { |
Contributor
There was a problem hiding this comment.
Is this creating an error? Because the delete call seems to be working just fine for switchport interfaces.
λ gnmic -a 127.0.0.1 -u admin -p admin --port 9339 --skip-verify get --path 'System/intf-items/phys-items/PhysIf-list[id=eth1/12]/layer' --values-only --type config
[
"Layer2"
]
λ gnmic -a 127.0.0.1 -u admin -p admin --port 9339 --skip-verify set --delete 'System/icmpv4-items/inst-items/dom-items/Dom-list[name=default]/if-items/If-list[id=eth1/12]'
{
"source": "127.0.0.1",
"timestamp": 1773406679784925525,
"time": "2026-03-13T13:57:59.784925525+01:00",
"results": [
{
"operation": "DELETE",
"path": "System/icmpv4-items/inst-items/dom-items/Dom-list[name=default]/if-items/If-list[id=eth1/12]"
}
]
}
Contributor
Author
There was a problem hiding this comment.
Ignore this commit for now, i am still investigating an issue that may have some relation to this. One thing that caught our attention is that we configure icmp settings on interfaces that have no addressing configured. I will probably change this and push into this PR.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.