本帖最后由 高迪 于 2018-5-30 15:30 编辑
neutron port-show f0698a82-0800-4e3a-a426-b06c9f929eb2
+-----------------------+----------------------------------------------------------------------------------------+
| Field | Value |
+-----------------------+----------------------------------------------------------------------------------------+
| admin_state_up | True |
| allowed_address_pairs | |
| binding:host_id | openstack-04 |
| binding:profile | {"network": 1} |
| binding:vif_details | {"port_filter": true, "ovs_hybrid_plug": true} |
| binding:vif_type | ovs |
| binding:vnic_type | normal |
| device_id | cec5b286-e1ef-4078-a843-45358552b1f8 |
| device_owner | compute:nova |
| extra_dhcp_opts | |
| fixed_ips | {"subnet_id": "6859d408-1e17-4d10-92ee-285476793acf", "ip_address": "192.168.150.105"} |
| id | f0698a82-0800-4e3a-a426-b06c9f929eb2 |
| mac_address | fa:16:3e:54:17:52 |
| name | |
| network_id | 32d328b6-457e-4d0b-89df-e36aabb684b8 |
| security_groups | 1bd456c7-ed53-41c1-bc83-f00a0abed62f |
| status | ACTIVE |
| tenant_id | 768f1266e2424503b2523bdfa9af76c4 |
+-----------------------+----------------------------------------------------------------------------------------+
需要对 fixed_ips选项更新一下ip地址
#neutron port-update --fixed-ip={"subnet_id": "6859d408-1e17-4d10-92ee-285476793acf", "ip_address": "192.168.150.102"} 774e62d4-a8c1-42c9-b1e1-a0a755235895
执行时报错
Bad Request (HTTP 400) (Request-ID: req-141eb688-a5f8-4069-8007-06f10f7ca658)
如果把逗号改成空格,就报下面这个错误
Duplicated options --fixed_ips=subnet_id:6859d408-1e17-4d10-92ee-285476793acf --fixed_ips=ip_address:192.168.150.102
换了很多种执行方式都是报错,因为是2个键值,用逗号隔开了,提交时就会报错,对于这种有2个值的,需要用什么样的格式才能正确提交?
|
|