[YANGTOOLS-805] Cannot mount netconf device Created: 07/Aug/17  Updated: 10/Apr/22  Resolved: 10/Aug/17

Status: Verified
Project: yangtools
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Marek Gradzki Assignee: Igor Foltin
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


Attachments: Zip Archive karaf.log.zip     Zip Archive odl_logs.zip    
Issue Links:
Duplicate
is duplicated by NETCONF-445 N: GET for netconf device mount point... Resolved
External issue ID: 8940
Priority: High

 Description   

I am trying to mount netconf device as explained on the wiki (but using JSON, because XML is not working currently):

https://wiki.opendaylight.org/view/OpenDaylight_Controller:Config:Examples:Netconf#Spawning_netconf_connectors_via_topology_configuration

feature:install odl-netconf-topology odl-restconf-all

then

PUT http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/vpp

{
"node":

{ "node-id": "vpp", "host": "127.0.0.1", "port": 7777, "username": "admin", "password": "admin", "tcp-only": true, "keepalive-delay": 0 }

}

[Fatal Error] :15:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :15:24: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :12:27: Element type "https:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :25:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :17:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :10:25: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :24:25: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :10:27: Element type "https:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :10:22: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :281:38: The entity name must immediately follow the '&' in the entity reference.
[Fatal Error] :24:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :6:35: Element type "ttkacik" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :11:36: Element type "milfabia" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :8:34: Element type "mbobak" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :18:18: Element type "mailto:iana" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :10:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :33:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :13:28: Element type "mailto:andy" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :19:23: Element type "http:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :12:35: Element type "ssenthil" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :11:35: Element type "rovarga" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :14:65: The entity name must immediately follow the '&' in the entity reference.
[Fatal Error] :13:24: Element type "https:" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :21:26: Element type "fcoras" must be followed by either attribute specifications, ">" or "/>".
[Fatal Error] :12:36: Element type "milfabia" must be followed by either attribute specifications, ">" or "/>".
2017-08-07 13:11:06,726 | WARN | sing-executor-11 | NetconfDevice | 302 - org.opendaylight.netconf.sal-netconf-connector - 1.6.0.SNAPSHOT | RemoteDevice

{vpp}: Unable to build schema context, unsatisfied imports {RevisionSourceIdentifier [name=dhcp@2017-03-15]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-acl@2017-06-15]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=eid-mapping-context@2016-08-01]=[ModuleImportImpl [name=lisp, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=proxy-arp@2017-03-15]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=ietf-packet-fields@2016-07-08]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=network-topology@2013-10-21]=[ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=gpe-locator-pair-identification-context@2017-05-17]=[ModuleImportImpl [name=lisp, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=interface-acl@2016-12-14]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=gpe-entry-identification-context@2017-05-17]=[ModuleImportImpl [name=lisp, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-routing@2016-12-14]=[ModuleImportImpl [name=hc2vpp-ietf-routing, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=interface-nat@2017-08-01]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-nat, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-interface-acl@2017-03-15]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-pbb@2016-12-14]=[ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=interface-policer@2017-03-15]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-routing-ra@2017-05-02]=[ModuleImportImpl [name=hc2vpp-ietf-routing, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=hc2vpp-ietf-ipv6-unicast-routing, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=network-topology@2013-07-12]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-classifier-acl@2017-05-03]=[ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=gpe@2017-05-18]=[ModuleImportImpl [name=lisp, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=ietf-access-control-list@2016-07-08]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=multi-naming-context@2016-04-11]=[ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=subinterface-nat@2017-06-15]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=subinterface-span@2017-06-07]=[ModuleImportImpl [name=v3po, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=interface-role@2017-06-15]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=nat-context@2016-12-14]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=ietf-lisp-address-types@2015-11-05]=[ModuleImportImpl [name=ietf-yang-types, revision=2013-07-15, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-vlan@2017-06-07]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=v3po, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=opendaylight-rest-connector@2014-07-24]=[ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-classifier@2017-03-27]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=nc-notifications@2008-07-14]=[ModuleImportImpl [name=ietf-yang-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=policer@2017-03-15]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=pbb-types@2016-12-14]=[ModuleImportImpl [name=ietf-yang-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-acl-context@2017-01-04]=[ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=vpp-subinterface-acl@2017-03-15]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=unnumbered-interfaces@2017-05-10]=[ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=adjacencies-identification-context@2016-08-01]=[ModuleImportImpl [name=lisp, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=sal-remote-augment@2014-07-08]=[ModuleImportImpl [name=sal-remote, revision=2014-01-14, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=notifications@2008-07-14]=[ModuleImportImpl [name=ietf-yang-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=nd-proxy@2017-03-15]=[ModuleImportImpl [name=ietf-ip, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=ietf-interfaces, revision=null, semanticVersion=0.0.0], ModuleImportImpl [name=yang-ext, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=ietf-netconf-monitoring-extension@2013-12-10]=[ModuleImportImpl [name=ietf-netconf-monitoring, revision=null, semanticVersion=0.0.0]]}, will reattempt with resolved only

It looks like adding explicit dependencies version to models does not help (tried only dhcp@2017-03-15):

import ietf-inet-types { prefix inet; revision-date 2013-07-15; }

and got:
017-08-07 13:15:21,993 | WARN | sing-executor-11 | NetconfDevice | 302 - org.opendaylight.netconf.sal-netconf-connector - 1.6.0.SNAPSHOT | RemoteDevice{vpp}

: Unable to build schema context, unsatisfied imports {RevisionSourceIdentifier [name=dhcp@2017-03-15]=[ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]],...

The ietf-inet-types@2013-07-15 model is sent by device in response to get-schema message. I was using netconf/caraf from local build (033e972eaf0d009ed0c0f54a109b6046fae80c99).
Detailed logs attached.



 Comments   
Comment by Marek Gradzki [ 07/Aug/17 ]

Attachment karaf.log.zip has been added with description: karaf4 log

Comment by Marek Gradzki [ 07/Aug/17 ]

Attachment odl_logs.zip has been added with description: full karaf log

Comment by Marek Gradzki [ 08/Aug/17 ]

Issue occurs when netconf/karaf from master branch is used, commit id: 033e972eaf0d009ed0c0f54a109b6046fae80c99. Everything works fine with carbon distros.

Our users observed the issue started to occur after strict parsing rules for xml in yangtool project got merged:
https://git.opendaylight.org/gerrit/#/c/59167/

More details here:
https://jira.fd.io/browse/HC2VPP-198

HC is currently using ODL Carbon-SR1, but the issue was present with Boron-SR4.

Comment by Marek Gradzki [ 08/Aug/17 ]

Issue also occurs for Honeycomb without VPP plugins loaded.
Steps to reproduce:

Checkout and build:
https://gerrit.fd.io/r/#/c/6924/

(or its parent for testing Boron compatibility).

Run HC:

sudo ./honeycomb/infra/minimal-distribution/target/minimal-distribution-1.17.10-SNAPSHOT-hc/minimal-distribution-1.17.10-SNAPSHOT/honeycomb

or debug version (port 5005):

sudo ./honeycomb/infra/minimal-distribution/target/minimal-distribution-1.17.10-SNAPSHOT-hc/minimal-distribution-1.17.10-SNAPSHOT/honeycomb-debug

Mount fails with exception:
2017-08-08 10:29:12,949 | WARN | sing-executor-11 | NetconfDevice | 302 - org.opendaylight.netconf.sal-netconf-connector - 1.6.0.SNAPSHOT | RemoteDevice

{vpp}

: Unable to build schema context, unsatisfied imports

{RevisionSourceIdentifier [name=opendaylight-rest-connector@2014-07-24]=[ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=network-topology@2013-07-12]=[ModuleImportImpl [name=ietf-inet-types, revision=null, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=network-topology@2013-10-21]=[ModuleImportImpl [name=ietf-inet-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=sal-remote-augment@2014-07-08]=[ModuleImportImpl [name=sal-remote, revision=2014-01-14, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=nc-notifications@2008-07-14]=[ModuleImportImpl [name=ietf-yang-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=notifications@2008-07-14]=[ModuleImportImpl [name=ietf-yang-types, revision=2013-07-15, semanticVersion=0.0.0]], RevisionSourceIdentifier [name=ietf-netconf-monitoring-extension@2013-12-10]=[ModuleImportImpl [name=ietf-netconf-monitoring, revision=null, semanticVersion=0.0.0]]}

, will reattempt with resolved only

To check device is indeed not mounted correctly it is enough to invoke:

GET http://localhost:8181/restconf/operational/network-topology:network-topology/topology/topology-netconf/node/vpp/yang-ext:mount/ietf-netconf-monitoring:netconf-state

Which works directly:
GET http://localhost:8183/restconf/operational/ietf-netconf-monitoring:netconf-state

Comment by Igor Foltin [ 09/Aug/17 ]

Fix: https://git.opendaylight.org/gerrit/#/c/61421/

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