...
Table of Contents | ||
---|---|---|
|
Contributors
Name | Organization | Role | |
---|---|---|---|
Andrea Campanella |
ONF | Developer |
andrea@opennetworking.us |
Helen Wu |
Developer |
Overview
This section provides an overview on the NETCONF protocol implementation in ONOS.
...
Code Block |
---|
onos> cfg get org.onosproject.netconf.ctl.impl.NetconfControllerImpl org.onosproject.netconf.ctl.impl.NetconfControllerImpl name=sshLibrary, type=string, value=apache-mina, defaultValue=apache-mina, description=Ssh Library instead of apache_mina (i.e. ethz-ssh2 name=netconfIdleTimeout, type=integer, value=300, defaultValue=300, description=Time (in seconds) SSH session will close if no traffic seen name=netconfConnectTimeout, type=integer, value=5, defaultValue=5, description=Time (in seconds) to wait for a NETCONF connect. name=netconfReplyTimeout, type=integer, value=5, defaultValue=5, description=Time (in seconds) waiting for a NetConf reply onos> |
...
Values for individual devices are settable through the Network Configuration Service. Under the "netconf" grouping the following additional attributes can be optionally added in any order
...
If individual device settings exist for a device, they will take priority over system wide settings for that device. It is at the creation of the NETCONF session that the values are taken in to account and changing them after that will have no effect on that session. If the session is closed however, and a new session opened, then any new values are taken in to account.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
"devices": { <device-id>: { "netconf": { "username": <user>, "password": <pw>, "ip": <ip>, "port": <port>, "connect-timeout": 20, "reply-timeout": 25 }, |
...
SSH Client
Two different SSH Client libraries are available in ONOS for NETCONF connections - Apache Mina SSH Client and Ganymede SSH Client - Apache Mina is the default library.
...
- "ssh-client": <value - either "ethz-ssh2" or "apache-mina">
...
Example: Get and Set Controllers.
...
To test locally (not on real switches) the NETCONF implementation you need the Mininet machine with of-config installed (link to mininet machine).
VM | Description | Comments |
---|---|---|
onos-ofconfig-mininet.ova | Mininet machine with of-config installed | Username / Password: mininet/ mininet |
of-config is wrapper for an openvswitch instance, that uses NETCONF protocol and translates it to OVSDB in order to use that database implementation.
...
There is much room for improvement and testing, this is only a basic skeleton of the infrastructure. The improvement should be focused on extracting the XML that is now encoded in the NetconfSessionImpl's methods and testing each operation. In the future the XML can be generated through YANG models so it can be specific for every type of device we want to connect.