Don't mind,port list information after every step as follows(the network has only one subnet):
1.Before subnet added into the router, 'total_ips' of network does not contain 'gateway_ip','used_ips' of network does not contain 'gateway_ip'
[root@localhost devstack]# neutron net-show net_test +---------------------------+--------------------------------------+ | Field | Value | +---------------------------+--------------------------------------+ | admin_state_up | True | | availability_zone_hints | | | availability_zones | zone-1 | | created_at | 2016-05-26T14:44:36 | | description | | | id | 83dc21b4-715b-4f74-9db6-012ccf13c8ef | | ipv4_address_scope | | | ipv6_address_scope | | | mtu | 4950 | | name | net_test | | provider:network_type | vxlan | | provider:physical_network | | | provider:segmentation_id | 1040 | | qos_policy_id | | | router:external | False | | shared | False | | status | ACTIVE | | subnets | 63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118 | | tags | | | tenant_id | ee4bd2aeeac74bb3ad2b094fc5292cbf | | updated_at | 2016-05-26T14:44:36 | | vlan_transparent | False | +---------------------------+--------------------------------------+ [root@localhost devstack]# neutron port-list|grep 63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118 | 99d84483-f15f-4ec6-97ff-782dc865cc64 | | fa:16:3e:22:54:c8 | {"subnet_id": "63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118", "ip_address": "105.1.1.6"} |
[root@localhost devstack]# neutron net-ip-availability-list +--------------------------------------+-------------------+-----------+----------+ | network_id | network_name | total_ips | used_ips | +--------------------------------------+-------------------+-----------+----------+ | 83dc21b4-715b-4f74-9db6-012ccf13c8ef | net_test | 5 | 1 | +--------------------------------------+-------------------+-----------+----------+
2.After subnet added into the router,'total_ips' of network does not contain 'gateway_ip',However,'used_ips' of network contains 'gateway_ip'
[root@localhost devstack]# neutron router-interface-add router_az_01 subnet=63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118 Added interface 1fcae454-34a9-4b09-9428-c7824a653bf7 to router router_az_01.
[root@localhost devstack]# neutron net-ip-availability-list +--------------------------------------+-------------------+-----------+----------+ | network_id | network_name | total_ips | used_ips | +--------------------------------------+-------------------+-----------+----------+ | 83dc21b4-715b-4f74-9db6-012ccf13c8ef | net_test | 5 | 2 | +--------------------------------------+-------------------+-----------+----------+
[root@localhost devstack]# neutron port-list|grep 63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118 | 1fcae454-34a9-4b09-9428-c7824a653bf7 | | fa:16:3e:a8:e7:62 | {"subnet_id": "63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118", "ip_address": "105.1.1.1"} | | 99d84483-f15f-4ec6-97ff-782dc865cc64 | | fa:16:3e:22:54:c8 | {"subnet_id": "63aa67d0-55e4-4cb0-8dcb-cdc7d2c83118", "ip_address": "105.1.1.6"} | [root@localhost devstack]#
Don't mind,port list information after every step as follows(the network has only one subnet):
1.Before subnet added into the router, 'total_ips' of network does not contain 'gateway_ ip','used_ ips' of network does not contain 'gateway_ip'
[root@localhost devstack]# neutron net-show net_test ------- ------- ------- +------ ------- ------- ------- ------- ----+ ------- ------- ------- +------ ------- ------- ------- ------- ----+ zone_hints | | 715b-4f74- 9db6-012ccf13c8 ef | network_ type | vxlan | physical_ network | | segmentation_ id | 1040 | 55e4-4cb0- 8dcb-cdc7d2c831 18 | 3ad2b094fc5292c bf | ------- ------- ------- +------ ------- ------- ------- ------- ----+ 55e4-4cb0- 8dcb-cdc7d2c831 18 f15f-4ec6- 97ff-782dc865cc 64 | | fa:16:3e:22:54:c8 | {"subnet_id": "63aa67d0- 55e4-4cb0- 8dcb-cdc7d2c831 18", "ip_address": "105.1.1.6"} |
+------
| Field | Value |
+------
| admin_state_up | True |
| availability_
| availability_zones | zone-1 |
| created_at | 2016-05-26T14:44:36 |
| description | |
| id | 83dc21b4-
| ipv4_address_scope | |
| ipv6_address_scope | |
| mtu | 4950 |
| name | net_test |
| provider:
| provider:
| provider:
| qos_policy_id | |
| router:external | False |
| shared | False |
| status | ACTIVE |
| subnets | 63aa67d0-
| tags | |
| tenant_id | ee4bd2aeeac74bb
| updated_at | 2016-05-26T14:44:36 |
| vlan_transparent | False |
+------
[root@localhost devstack]# neutron port-list|grep 63aa67d0-
| 99d84483-
[root@localhost devstack]# neutron net-ip- availability- list ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+ ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+ 715b-4f74- 9db6-012ccf13c8 ef | net_test | 5 | 1 | ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+
+------
| network_id | network_name | total_ips | used_ips |
+------
| 83dc21b4-
+------
2.After subnet added into the router,'total_ips' of network does not contain 'gateway_ ip',However, 'used_ips' of network contains 'gateway_ip'
[root@localhost devstack]# neutron router- interface- add router_az_01 subnet= 63aa67d0- 55e4-4cb0- 8dcb-cdc7d2c831 18 34a9-4b09- 9428-c7824a653b f7 to router router_az_01.
Added interface 1fcae454-
[root@localhost devstack]# neutron net-ip- availability- list ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+ ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+ 715b-4f74- 9db6-012ccf13c8 ef | net_test | 5 | 2 | ------- ------- ------- ------- ----+-- ------- ------- ---+--- ------- -+----- -----+
+------
| network_id | network_name | total_ips | used_ips |
+------
| 83dc21b4-
+------
[root@localhost devstack]# neutron port-list|grep 63aa67d0- 55e4-4cb0- 8dcb-cdc7d2c831 18 34a9-4b09- 9428-c7824a653b f7 | | fa:16:3e:a8:e7:62 | {"subnet_id": "63aa67d0- 55e4-4cb0- 8dcb-cdc7d2c831 18", "ip_address": "105.1.1.1"} | f15f-4ec6- 97ff-782dc865cc 64 | | fa:16:3e:22:54:c8 | {"subnet_id": "63aa67d0- 55e4-4cb0- 8dcb-cdc7d2c831 18", "ip_address": "105.1.1.6"} |
| 1fcae454-
| 99d84483-
[root@localhost devstack]#