[CONTROLLER-166] Opendaylight can not mount remote device Created: 20/Feb/14  Updated: 25/Jul/23  Resolved: 27/Feb/14

Status: Resolved
Project: controller
Component/s: netconf
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Reinaldo Penno Assignee: Unassigned
Resolution: Cannot Reproduce Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: Mac OS
Platform: PC


Attachments: Text File netconflogs.txt    
Issue Links:
Duplicate
is duplicated by CONTROLLER-131 issuing a restconf command to see the... Resolved
External issue ID: 435
Priority: High

 Description   

After ODL establishes a Netconf session (as client) to libnetconfd (as server) I try to use REST interface to get device characteristics.

http://127.0.0.1:8080/restconf/operational/opendaylight-inventory:nodes/node/libnetconfd/yang-ext:mount

But the reply is:

"Mount point does not contain any schema with modules."

Attached goes the logs of the netconf session setup between ODL and libnetconfd

The actual GET request does not generate any packets towards the server. It is handled locally in ODL



 Comments   
Comment by Reinaldo Penno [ 20/Feb/14 ]

Attachment netconflogs.txt has been added with description: Logs of netconf session between ODL and libnetconfd

Comment by Reinaldo Penno [ 21/Feb/14 ]

libnetconfd version:

http://code.google.com/p/libnetconf/

libnetconf-0.7 was released in February 2014

Netopeer:

http://code.google.com/p/netopeer/

Latest version

Comment by Tony Tkacik [ 27/Feb/14 ]

From analysis of the logs, we found out that response from libnetconfd is mallformed:

When issuing get-schema RPC from ietf-netconf monitoring namespace is: urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring

As in get-schema

<get-schema xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring">
<format>yang</format>
<identifier>ietf-netconf</identifier>
<version>2011-03-08</version>
</get-schema>
</rpc>

But data element in response is from base namespace, but it should be
urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring as defined in YANG specification.

That is why ODL (which is strict about namespaces) did not process schema,
because get-schema response was invalid.

The incorrect reply (from libnetconfd, could be seen in attached logs) is bellow:

<?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="m-9">
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">module "ietf-netconf" {
namespace "urn:ietf:params:xml:ns:netconf:base:1.0";
prefix "nc";
...
...
...

The root reason is bug in libnetconf.

Comment by Tony Tkacik [ 27/Feb/14 ]

Opened a bug report in netopeer:

https://code.google.com/p/netopeer/issues/detail?id=10

Generated at Wed Feb 07 19:52:21 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.