Launchpad

No default ip-version for "ip availability list" command

Bug #1592761 reported by aohuanxuan

This bug affects 1 person

Affects Status Importance Assigned to Milestone
python-openstackclient

Fix Released

Undecided

aohuanxuan

Bug Description

There is not a default ip-version in "ip availability list" command, so there are some errors when we use the command without "--ip-version" option.
(openstack) ip availability list
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| Network ID | Network Name | Total IPs | Used IPs |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 184467440737095 51867 | 2 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 184467440737095 51867 | 4 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
(openstack) ip availability list --ip-version 4
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| Network ID | Network Name | Total IPs | Used IPs |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 253 | 1 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 253 | 2 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
(openstack) ip availability list --ip-version 6
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| Network ID | Network Name | Total IPs | Used IPs |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 184467440737095 51614 | 1 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 184467440737095 51614 | 2 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
We can see there are 3 different outputs.
Comparing with the output of the command in neutronclient.
(neutron) net-ip- availability- list
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| network_id | network_name | total_ips | used_ips |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 253 | 1 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 253 | 2 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
(neutron) net-ip- availability- list --ip-version 4
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| network_id | network_name | total_ips | used_ips |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 253 | 1 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 253 | 2 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ---+--- ------- +
(neutron) net-ip- availability- list --ip-version 6
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| network_id | network_name | total_ips | used_ips |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
| 4ea57678- cbdd-4a78- bab6-2c8556197d b6 | public | 184467440737095 51614 | 1 |
| b2ea9074- c559-4151- b2fb-bffb08af1e 66 | private | 184467440737095 51614 | 2 |
+------ ------- ------- ------- ------- ----+-- ------- -----+- ------- ------- ------- +------ ----+
We can find that if we use the "ip availability list" command of OSC without "--ip-version" option.
the output is wrong.
So, I think we need add the default ip-version for the "ip availability list" command in OSC.

Read the original on bugs.launchpad.net ↗