Hi,
I have this config applied to the router (IOS XE 16.9.3):
csr1000v#sh run | se bgp
router bgp 65111
bgp log-neighbor-changes
network 10.1.1.1 mask 255.255.255.255
network 10.1.1.2 mask 255.255.255.255
network 10.1.1.3 mask 255.255.255.255
redistribute connected
neighbor 10.10.10.11 remote-as 65111
neighbor 10.10.10.11 description AUTO1
neighbor 10.10.10.12 remote-as 65111
neighbor 10.10.10.12 update-source GigabitEthernet1
neighbor 10.20.20.20 remote-as 65222
neighbor 10.20.20.20 route-map NETC out
csr1000v#
But when I try to get it via NETCONF or RESTCONF, some commands are missing. That is “network x.x.x.x” and “redistribute” and “neighbor route-map” are missing. How can I get them via REST or NETCONF? Check the output below.
curl -k -i --header "Accept: application/yang-data+json" -u developer:C1sco12345 "https://ios-xe-mgmt.cisco.com:9443/restconf/data/Cisco-IOS-XE-native:native/router"
HTTP/1.1 200 OK
Server: nginx
Date: Wed, 05 Aug 2020 23:37:24 GMT
Content-Type: application/yang-data+json
Transfer-Encoding: chunked
Connection: keep-alive
Cache-Control: private, no-cache, must-revalidate, proxy-revalidate
Pragma: no-cache
{
"Cisco-IOS-XE-native:router": {
"Cisco-IOS-XE-bgp:bgp": [
{
"id": 65111,
"bgp": {
"log-neighbor-changes": true
},
"neighbor": [
{
"id": "10.10.10.11",
"remote-as": 65111,
"description": "AUTO1"
},
{
"id": "10.10.10.12",
"remote-as": 65111,
"update-source": {
"GigabitEthernet": "1"
}
},
{
"id": "10.20.20.20",
"remote-as": 65222
}
]
}
]
}
}
Thank you very much!!