... | @@ -16,10 +16,10 @@ https://wiki.openstack.org/wiki/Neutron/APIv2-specification#Show_Network |
... | @@ -16,10 +16,10 @@ https://wiki.openstack.org/wiki/Neutron/APIv2-specification#Show_Network |
|
```bash
|
|
```bash
|
|
# opendaylight neutron api (password should be known to you, port ids can be listed on /ports with GET)
|
|
# opendaylight neutron api (password should be known to you, port ids can be listed on /ports with GET)
|
|
curl --user "admin":"$PASSWORD" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
curl --user "admin":"$PASSWORD" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
-X PUT -d '{"port": {"name": "port1 updated"}}' http://sdncontrol:8080/controller/nb/v2/neutron/port/$PORT_ID
|
|
-X PUT -d '{"port": {"name": "port1 updated"}}' http://sdncontrol:8080/controller/nb/v2/neutron/port/$PORT_ID; echo
|
|
# neutron api on controlnode (get token from /var/log/nova/compute.log)
|
|
# neutron api on controlnode (get token from /var/log/nova/compute.log)
|
|
curl -H "X-Auth-Token: $(cat token)" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
curl -H "X-Auth-Token: $(cat token)" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
-X GET http://controlnode:9696/v2.0/ports.json 2>/dev/null | sed "s/,/,\n/g";echo;
|
|
-X GET http://controlnode:9696/v2.0/ports.json 2>/dev/null | sed "s/,/,\n/g"; echo
|
|
```
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
\ No newline at end of file |