Topology 2 is a "region aware" view of the topology, where the administrator can configure the network into regions and sub-regions.
In its default state (where no "regions" or "layouts" are defined), it should look and behave similarly to the "classic" Topology view.
Note that this view is currently "experimental".
The ONOS model of the network includes Region objects which can be configured with a collection of Devices (switches) "belonging" to that region.
Regions can be configured using a number of CLI commands:
To add a region to the model, the region-add command can be used..
region-add <region-id> <region-name> <region-type> <lat/Y> <long/X> <locType> <region-master>
where:
A couple of examples:
region-add rUK "United Kingdom" COUNTRY 52.206035 -1.310384 geo "192.168.56.101 / 192.168.56.102" region-add rRack1 "Primary Rack" RACK 15.0 20.0 grid 10.0.0.5 |
Note that CLI commands are scriptable. One way of doing this is as follows:
#!/bin/bash host=${1:-localhost} onos ${host} <<-EOF region-add rUK "United Kingdom" COUNTRY 52.206035 -1.310384 geo ${host} region-add rIT "Italy" COUNTRY 44.447951 11.093161 geo ${host} region-add rFR "France" COUNTRY 47.066264 2.711458 geo ${host} EOF |
Devices can be assigned to regions with the region-add-devices command:
region-add-devices <region-id> <dev1> <dev2> ... <dev-n>
where
For example:
region-add-devices rUK \ of:0000000000000001 \ of:0000000000000002 \ of:0000000000000003 |