Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »


1. Topology preparation

The topology of this demo contains three nodes:

  • 2 Cassini terminal devices - You can pull the image from dockerhub via command

    docker pull onosproject/oc-cassini:0.21
  • 1 TAPI-2.1 OLS device - You can pull the image from dockerhub via command

    docker pull onosproject/tapi-2.1:0.02


Then, the topo configuration file consists of two json files:

  • device.json: You can download this file via command

    wget https://raw.githubusercontent.com/opennetworkinglab/ODTN-emulator/master/topo/with-rest-tapi/device.json

    The content is:

    {
      "devices" : {
        "netconf:127.0.0.1:11002" : {
          "basic" : {
            "name":"cassini2",
            "driver":"cassini-ocnos"
          },
          "netconf" : {
            "ip" : "127.0.0.1",
            "port" : "11002",
            "username" : "root",
            "password" : "root",
            "idle-timeout" : "0"
          }
        },
        "rest:127.0.0.1:11000": {
          "rest": {
            "ip": "127.0.0.1",
            "port": 11000,
            "protocol": "http",
            "testUrl":"/restconf/data/tapi-common:context",
            "manufacturer": "tapi-swagger",
            "hwVersion": "0",
            "swVersion": "2.1"
          },
          "basic": {
            "driver": "ols"
          }
        },
        "netconf:127.0.0.1:11003" : {
          "basic" : {
            "name":"cassini1",
            "driver":"cassini-ocnos"
          },
          "netconf" : {
            "ip" : "127.0.0.1",
            "port" : "11003",
            "username" : "root",
            "password" : "root",
            "idle-timeout" : "0"
          }
        }
      }
    }
  • link.json: You can download this file via command

    wget https://raw.githubusercontent.com/opennetworkinglab/ODTN-emulator/master/topo/with-rest-tapi/link.json

    The content is:

    {
      "links": {
        "netconf:127.0.0.1:11002/201-rest:127.0.0.1:11000/100000035178": {
          "basic": {
            "type": "OPTICAL",
            "metric": 1,
            "durable": true,
            "bidirectional": true
          }
        },
        "rest:127.0.0.1:11000/100000035182-netconf:127.0.0.1:11003/201": {
          "basic": {
            "type": "OPTICAL",
            "metric": 1,
            "durable": true,
            "bidirectional": true
          }
        }
      }
    }

2. Run Topology and ONOS instance

Firstly, start three device emulator:

docker run -it -d --name odtn-emulator_openconfig_cassini_1_1 -p 11002:830 onosproject/oc-cassini:0.21
docker run -it -d --name odtn-emulator_openconfig_cassini_2_1 -p 11003:830 onosproject/oc-cassini:0.21
docker run -it -d --name odtn-emulator_tapi_ols_1 -p 11000:1234 onosproject/tapi-2.1:0.02

And you will see three containers running:

ONFs-MacBook-Pro:tapi2.1-javaServer onf$ docker ps -a
CONTAINER ID        IMAGE                         COMMAND                  CREATED             STATUS              PORTS                                      NAMES
8eafc849aa22        onosproject/tapi-2.1:0.02     "sh /root/script/ent…"   About an hour ago   Up About an hour    0.0.0.0:11000->1234/tcp                    odtn-emulator_tapi_ols_1
4cdd162d17ac        onosproject/oc-cassini:0.21   "sh /root/script/pus…"   4 hours ago         Up About an hour    22/tcp, 8080/tcp, 0.0.0.0:11003->830/tcp   odtn-emulator_openconfig_cassini_2_1
31a67778f3b7        onosproject/oc-cassini:0.21   "sh /root/script/pus…"   4 hours ago         Up About an hour    22/tcp, 8080/tcp, 0.0.0.0:11002->830/tcp   odtn-emulator_openconfig_cassini_1_1


Meanwhile, run the ONOS instance locally:

cd $ONOS_ROOT
export ONOS_APPS=odtn-service,drivers,gui2
bazel run onos-local -- clean

Secondly, push topology info into ONOS controller:

onos-netcfg localhost device.json
onos-netcfg localhost link.json

Open the webpage, you will see the topology:

3. Connectivity Creation/Deletion

Now, you can execute connectivity operations based on the topology and the controller.

  • No labels