cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
702
Views
5
Helpful
1
Replies

IOS-XR lldp neighbors issue when using netconf to aristar the character ':' is not liked in a string

shillyar
Cisco Employee
Cisco Employee
Hello,
 
When I programmatically - from a controller - try to get "lldp neighbors" using NETCONF, on the Cisco device, I see the following error (highlighted) for a neighbor Arista device. A neighbor Cisco device does not result in this error: 8:37:14.114 PM [ULNET] 2021-03-10 20:37:14,113: ERROR - tornado.application.log_exception user:root hostname: message:Uncaught exception GET /v0/nv (10.70.25.8) HTTPServerRequest(protocol='http', host='10.137.158.202:8003', method='GET', uri='/v0/nv', version='HTTP/1.1', remote_ip='10.70.25.8') Traceback (most recent call last): File "/usr/local/lib/python3.8/site-packages/tornado/web.py", line 1704, in _execute result = await result File "/app/network_validation/views.py", line 41, in get await run_nv(self.processor, self.network_name, self.nv_webhook_url, self.logger) File "/app/network_validation/nv.py", line 157, in run_nv read_device_info(mgmt_ip) File "/app/network_validation/nv.py", line 49, in read_device_info lldp = crud.read(provider, Lldp()) File "/usr/local/lib/python3.8/site-packages/ydk/services/crud_service.py", line 60, in read return _crud_read(provider, read_filter, False, self._crud.read) File "/usr/local/lib/python3.8/site-packages/ydk/services/crud_service.py", line 88, in _crud_read read_top_entity = crud_call(provider, top_filters) File "/usr/local/lib/python3.8/contextlib.py", line 131, in __exit__ self.gen.throw(type, value, traceback) File "/usr/local/lib/python3.8/site-packages/ydk/errors/error_handler.py", line 82, in handle_runtime_error _raise(_exc) File "/usr/local/lib/python3.8/site-packages/ydk/errors/error_handler.py", line 54, in _raise exec("raise exc from None") File "<string>", line 1, in <module> ydk.errors.YModelError: Unexpected character(s) ':' (:00:00:00:00). Path: /openconfig-lldp:lldp/interfaces/interface[name='HundredGigE0/0/1/3']/neighbors/neighbor[id='tor02-arista.esa#Ethernet52/1']/custom-tlvs/tlv[oui='4623']/state/value
 
I found where the issue occurs, the character ':' is not liked in a string ':00:00:00:00'
 
                ydk.errors.YModelError:  Unexpected character(s) ':' (:00:00:00:00)

 

   We were looking at the TCP dump,
 
        18:31:54.518312 fc:bd:67:10:a0:70 (oui Unknown) > 01:80:c2:00:00:0e (oui Unknown), ethertype LLDP (0x88cc), length 225: LLDP, length 211 Chassis ID TLV (1), length 7 Subtype MAC address (4): fc:bd:67:10:a0:37 (oui Unknown)
        0x0000: 04fc bd67 10a0 37
        Port ID TLV (2), length 13
 
The raw netconf get appears to be successful.
 
So this would be a problem  somewhere in YDK ?
 
Thanks
1 Reply 1

yangorelik
Spotlight
Spotlight

From openconfig-lldp.yang taken this definition of leaf 'value':

    // TODO: consider making this string type
    leaf value {
      type binary;
      description
        "A variable-length octet-string containing the
        instance-specific information for this TLV.";
    }

Here type of the leaf is 'binary', therefore leaf value ':00:00:00:00' is invalid. Hence the error.

Does your device model have different definition such as suggested in TODO comments?

Could you also specify YDK version and device software release.

Yan Gorelik
YDK Solutions