
"dpid":"00:1e:f0:92:1c:21:af:00",
"owningControllerIp":"172.17.6.70"
}
]
},
{
"deviceIp":"192.168.1.104",
"owningControllerIp":"172.17.6.70",
"dataPaths":[
{
"dpid":"00:01:cc:3e:5f:6b:19:00",
"owningControllerIp":"172.17.6.70"
}
]
},
{
"deviceIp":"192.168.1.105",
"owningControllerIp":"172.17.6.70",
"dataPaths":[
{
"dpid":"00:1e:00:9c:02:e0:e4:00",
"owningControllerIp":"172.17.6.70"
}
]
}
]
}
]
}
Adding a region using curl
This
POST
command adds a region to those configured on the controller and propagates the
modifications to each controller in the team. All controllers configured for the team must be
available for such a configuration change to be permitted.
In this example, we are adding a region with UID
713def9a-4f96-485f-990c-8924bc06c8d8
that has three controllers:
172.17.6.70
(master),
172.17.6.71
(primary slave),
172.17.6.72
(secondary slave). Two devices are part of the region:
192.168.1.101
and
192.168.1.10
.
The devices IP range includes
192.168.1.103
,
192.168.1.104
,
192.168.1.105
Example command
curl --noproxy
controllerIp
--header "X-Auth-Token:
token
" --header "Content-Type:application/json"
-ksS --request
POST --url https://
controllerIp
:8443/sdn/v2.0/owners --data-binary
'{"region": {"name": "Region-Red",
"prioritizedControllerIps": ["172.17.6.70", "172.17.6.71", "172.17.6.72"], "deviceIps":["192.168.1.101",
"192.168.1.102"],"deviceIpRanges": ["192.168.1.103-105"]}}'
Example output
{
"region":{
"uid":"713def9a-4f96-485f-990c-8924bc06c8d8",
"name":"Region-Red",
"prioritizedControllerIps":[
"172.17.6.70",
"172.17.6.71",
"172.17.6.72"
],
"deviceIps":[
"192.168.1.101",
"192.168.1.102"
],
"deviceIpRanges":[
"192.168.1.103-105"
]
192
curl commands