HP VAN SDN Controller Administrator Guide

57
Configuration Example
This example shows a team of controllers configured with the following team member values:
Domain: sdn (the default domain name)
Username: myname
Password: mypass
Note
It is not mandatory that the team IP address be in the same subnet as the member
IP addresses. Other IP aliases can be used if the appropriate IP routes are present
for the addresses to be reachable and usable.
1. Enter the following cURL command to acquire the authentication token:
Caution
Credential information (user name, password, domain, and authentication tokens)
used in cURL commands may be saved in the command history. For security
reasons, HP recommends that you disable command history prior to executing
commands containing credential information.
curl --noproxy 192.0.2.119 -X POST --fail -ksSfL --url "https://
192.0.2.119:8443/sdn/v2.0/auth" -H "Content-Type: application/json" --data-
binary '{"login": {"domain": "sdn","user": "myname","password": "mypass"}}'
{“record”:{“token”:”10f728e477cb4612b07069f339d0ca29”,”expiration”:13811193
01000,”expirationDate”:2013-12-06 21-15-01-
0700”,”userId”:”51802e12d16345fe9a4389290c1a04e2”,”username”:”sdn”,”domainI
d”:”d45eca9bde1b4dc78bd7dff69ee9440d”,”domainName”:”sdn”}}
2. Configure the controller team by using the above team values and token to enter the
following curl command:
Note: The IP address used in this step should be the same as used in step 1.
curl --noproxy 192.0.2.119 --header X-Auth-Token:
10f728e477cb4612b07069f339d0ca29 --fail -ksS --request POST --url
https://192.0.2.119:8443/sdn/v2.0/team --data-binary
'{"team":{"name":"Test_Team","ip":"192.0.2.100","systems":[{"name":"Athos",
"ip":"192.0.0.119","priority":10},{"name":"Porthos","ip":"192.0.0.125","pri
ority":20},{"name":"Aramis","ip":"192.0.0.127","priority":30}]}}'
Completing the above steps creates and enables the “Test_Team”.
Team
Name
Team IP
Address
Member
Names
Member IP
Addresses
Member
Priority
Test_Team
192.0.2.100
Athos
Porthos
Aramis
192.0.2.119
192.0.2.125
192.0.2.127
10
20
30