lbaas: may need subnet/cidr checks before member and vip create

Bug #1506599 reported by Senthilnathan Murugappan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R3.0
New
Low
Unassigned
R3.1
New
Low
Unassigned
Trunk
New
Low
Unassigned

Bug Description

We may need to check for existence of subnet before lb-member create and lb-vip create

It would be better if vip-create fails when the pool subnet id is not found and member-create validates the address against cidr before creation.

root@a2s42:~/contrail-test# neutron net-list
| a2b7c585-1e04-496b-9721-b88328e05fc5 | vn-delete-subnet | da4bf80d-efa3-4f0b-8cb2-a33a99205017 1.1.1.0/24 |

root@a2s42:~/contrail-test# neutron lb-pool-create --lb-method ROUND_ROBIN --name pool-subnet-delete --protocol HTTP --subnet-id da4bf80d-efa3-4f0b-8cb2-a33a99205017

root@a2s42:~/contrail-test# neutron net-delete vn-delete-subnet

root@a2s42:~/contrail-test# neutron lb-member-create --protocol-port 80 --address 1.1.1.10 fe78f013-4a23-4e92-9cf3-cb3b381e2861
Created a new member:
+----------------+--------------------------------------+
| Field | Value |
+----------------+--------------------------------------+
| address | 1.1.1.10 |
| admin_state_up | True |
| id | f30e4175-53d8-43c2-bf4f-745f55469fb5 |
| pool_id | fe78f013-4a23-4e92-9cf3-cb3b381e2861 |
| protocol_port | 80 |
| status | ACTIVE |
| tenant_id | 7853038132294031befd30f641ca562b |
| weight | 1 |
+----------------+--------------------------------------+

root@a2s42:~/contrail-test# neutron lb-vip-create --name vip-subnet-delete --protocol-port 80 --protocol HTTP --subnet-id b641088e-9859-4db5-b503-61ef180e91ff fe78f013-4a23-4e92-9cf3-cb3b381e2861
Created a new vip:
+---------------------+--------------------------------------+
| Field | Value |
+---------------------+--------------------------------------+
| address | 6.6.6.3 |
| admin_state_up | True |
| connection_limit | -1 |
| description | |
| id | 99b2f8a1-f0c5-47a1-bd25-e27b56f5eb8c |
| name | vip-subnet-delete |
| pool_id | fe78f013-4a23-4e92-9cf3-cb3b381e2861 |
| port_id | c7bb18d0-3b49-4013-b4de-78a60c962b8a |
| protocol | HTTP |
| protocol_port | 80 |
| session_persistence | |
| status | ACTIVE |
| subnet_id | b641088e-9859-4db5-b503-61ef180e91ff |
| tenant_id | 7853038132294031befd30f641ca562b |
+---------------------+--------------------------------------+

==> /var/log/contrail/contrail-svc-monitor.log <==
10/15/2015 11:23:12 AM [a2s42:contrail-svc-monitor:Config:0]: __default__ [SYS_ERR]: SvcMonitorLog: Unknown id: Error: oper 2 url /virtual-network/a2b7c585-1e04-496b-9721-b88328e05fc5 body {'exclude_back_refs': True, 'exclude_children': True} response No virtual-network object found for id a2b7c585-1e04-496b-9721-b88328e05fc5

Tags: lbaas
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Bug update]

bug update...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.