11-14-2024 09:33 AM
We have encountered a strange issue with our ASR 1001x routers. We use RESTCONF to add IP's to a blocklist object group. Recently we had to remove an IP from that blocklist. In the CLI, we do not see the IP. However, when we run a GET method using RESTCONF for that object group, we do see the IP. Has anyone ever experienced this before? Is there something we are missing?
We are putting together an automated workflow and have four routers to run this workflow against. We need to make sure that we have consistent results so we can successfully complete this automation.
This is the cURL we are running:
curl --request GET --insecure -H 'Content-Type: application/yang-data+json' -u 'un:pw' https://X.X.X.X/restconf/data/Cisco-IOS-XE-native:native/object-group/Cisco-IOS-XE-object-group:network=blacklist_sources/obj-Mode-config-network-group/host
We can confirm that with a PATCH method, the IP is added. We have not approached removing IP's with RESTCONF as this is another phase of the project. But we cannot understand why we see differences in the CLI.
11-20-2024 06:59 AM
Interesting. Are you saying that each time we make a change with RESTCONF, we would need to run a full commit or refresh operation? If so, do you know how to do that with RESTCONF?
11-20-2024 07:40 AM
@JamesMathis as far as i know there is no direct "commit" or "refresh" operation like in some other configuration management protocols using RESTCONF.
I found this https://bst.cisco.com/quickview/bug/CSCwk43646 - reading over this, it matches your issue
Might be worth a TAC call or exploring more bugs for your software version.
11-19-2024 10:43 AM
Interesting case! It could be that the difference between CLI and RESTCONF views is a caching or synchronization issue on your routers configuration management plane. I’ve seen some inconsistencies between the management interfaces, especially during configuration changes, not this one, but my memory isn’t the best these day, something is sound familiar tho.
I wonder if this is a config sync delay between different management planes?
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide