2 Documentation Test suite to validate vpnservice functionality in an openstack integrated environment.
3 ... The assumption of this suite is that the environment is already configured with the proper
4 ... integration bridges and vxlan tunnels.
5 Suite Setup BuiltIn.Run Keywords SetupUtils.Setup_Utils_For_Setup_And_Teardown
6 ... AND DevstackUtils.Devstack Suite Setup
7 Suite Teardown Close All Connections
8 Test Setup SetupUtils.Setup_Test_With_Logging_And_Without_Fast_Failing
9 Test Teardown Get Test Teardown Debugs
10 Library OperatingSystem
11 Library RequestsLibrary
12 Resource ../../../libraries/Utils.robot
13 Resource ../../../libraries/OpenStackOperations.robot
14 Resource ../../../libraries/DevstackUtils.robot
15 Resource ../../../libraries/VpnOperations.robot
16 Resource ../../../libraries/OVSDB.robot
17 Resource ../../../libraries/SetupUtils.robot
18 Resource ../../../variables/Variables.robot
21 @{NETWORKS} NET10 NET20
22 @{SUBNETS} SUBNET1 SUBNET2
23 @{SUBNET_CIDR} 10.1.1.0/24 20.1.1.0/24
24 @{PORT_LIST} PORT11 PORT21 PORT12 PORT22
25 @{VM_INSTANCES_NET10} VM11 VM21
26 @{VM_INSTANCES_NET20} VM12 VM22
27 @{ROUTERS} ROUTER_1 ROUTER_2
28 @{VPN_INSTANCE_ID} 4ae8cd92-48ca-49b5-94e1-b2921a261111 4ae8cd92-48ca-49b5-94e1-b2921a261112 4ae8cd92-48ca-49b5-94e1-b2921a261113
29 @{VPN_NAME} vpn1 vpn2 vpn3
30 @{CREATE_RD} ["2200:2"] ["2300:2"] ["2400:2"]
31 @{CREATE_EXPORT_RT} ["2200:2"] ["2300:2"] ["2400:2"]
32 @{CREATE_IMPORT_RT} ["2200:2"] ["2300:2"] ["2400:2"]
33 @{EXTRA_NW_IP} 40.1.1.2 50.1.1.2
34 @{EXTRA_NW_SUBNET} 40.1.1.0/24 50.1.1.0/24
35 # Values passed for extra routes
36 ${RT_OPTIONS} --routes type=dict list=true
37 ${RT_CLEAR} --routes action=clear
40 Create Neutron Networks
41 [Documentation] Create two networks
42 Create Network ${NETWORKS[0]}
43 Create Network ${NETWORKS[1]}
44 ${NET_LIST} List Networks
46 Should Contain ${NET_LIST} ${NETWORKS[0]}
47 Should Contain ${NET_LIST} ${NETWORKS[1]}
48 Wait Until Keyword Succeeds 3s 1s Check For Elements At URI ${CONFIG_API}/neutron:neutron/networks/ ${NETWORKS}
50 Create Neutron Subnets
51 [Documentation] Create two subnets for previously created networks
52 Create SubNet ${NETWORKS[0]} ${SUBNETS[0]} ${SUBNET_CIDR[0]}
53 Create SubNet ${NETWORKS[1]} ${SUBNETS[1]} ${SUBNET_CIDR[1]}
54 ${SUB_LIST} List Subnets
56 Should Contain ${SUB_LIST} ${SUBNETS[0]}
57 Should Contain ${SUB_LIST} ${SUBNETS[1]}
58 Wait Until Keyword Succeeds 3s 1s Check For Elements At URI ${CONFIG_API}/neutron:neutron/subnets/ ${SUBNETS}
61 [Documentation] Allow all TCP/UDP/ICMP packets for this suite
62 Neutron Security Group Create sg-vpnservice
63 Neutron Security Group Rule Create sg-vpnservice direction=ingress port_range_max=65535 port_range_min=1 protocol=tcp remote_ip_prefix=0.0.0.0/0
64 Neutron Security Group Rule Create sg-vpnservice direction=egress port_range_max=65535 port_range_min=1 protocol=tcp remote_ip_prefix=0.0.0.0/0
65 Neutron Security Group Rule Create sg-vpnservice direction=ingress protocol=icmp remote_ip_prefix=0.0.0.0/0
66 Neutron Security Group Rule Create sg-vpnservice direction=egress protocol=icmp remote_ip_prefix=0.0.0.0/0
67 Neutron Security Group Rule Create sg-vpnservice direction=ingress port_range_max=65535 port_range_min=1 protocol=udp remote_ip_prefix=0.0.0.0/0
68 Neutron Security Group Rule Create sg-vpnservice direction=egress port_range_max=65535 port_range_min=1 protocol=udp remote_ip_prefix=0.0.0.0/0
71 [Documentation] Create four ports under previously created subnets
72 ${allowed_address_pairs_args}= Set Variable --allowed-address-pairs type=dict list=true ip_address=${EXTRA_NW_SUBNET[0]} ip_address=${EXTRA_NW_SUBNET[1]}
73 Create Port ${NETWORKS[0]} ${PORT_LIST[0]} sg=sg-vpnservice additional_args=${allowed_address_pairs_args}
74 Create Port ${NETWORKS[0]} ${PORT_LIST[1]} sg=sg-vpnservice additional_args=${allowed_address_pairs_args}
75 Create Port ${NETWORKS[1]} ${PORT_LIST[2]} sg=sg-vpnservice additional_args=${allowed_address_pairs_args}
76 Create Port ${NETWORKS[1]} ${PORT_LIST[3]} sg=sg-vpnservice additional_args=${allowed_address_pairs_args}
77 Wait Until Keyword Succeeds 3s 1s Check For Elements At URI ${CONFIG_API}/neutron:neutron/ports/ ${PORT_LIST}
80 [Documentation] Create Vm instances on compute node with port
81 Create Vm Instance With Port On Compute Node ${PORT_LIST[0]} ${VM_INSTANCES_NET10[0]} ${OS_COMPUTE_1_IP} sg=sg-vpnservice
82 Create Vm Instance With Port On Compute Node ${PORT_LIST[1]} ${VM_INSTANCES_NET10[1]} ${OS_COMPUTE_2_IP} sg=sg-vpnservice
83 Create Vm Instance With Port On Compute Node ${PORT_LIST[2]} ${VM_INSTANCES_NET20[0]} ${OS_COMPUTE_1_IP} sg=sg-vpnservice
84 Create Vm Instance With Port On Compute Node ${PORT_LIST[3]} ${VM_INSTANCES_NET20[1]} ${OS_COMPUTE_2_IP} sg=sg-vpnservice
85 ${VM_INSTANCES} = Create List @{VM_INSTANCES_NET10} @{VM_INSTANCES_NET20}
86 : FOR ${VM} IN @{VM_INSTANCES}
87 \ Wait Until Keyword Succeeds 25s 5s Verify VM Is ACTIVE ${VM}
89 Wait Until Keyword Succeeds 30s 10s Wait For Routes To Propogate
90 : FOR ${index} IN RANGE 1 5
91 \ ${VM_IP_NET10} ${DHCP_IP1} Wait Until Keyword Succeeds 30s 10s Verify VMs Received DHCP Lease
92 \ ... @{VM_INSTANCES_NET10}
93 \ ${VM_IP_NET20} ${DHCP_IP2} Wait Until Keyword Succeeds 30s 10s Verify VMs Received DHCP Lease
94 \ ... @{VM_INSTANCES_NET20}
95 \ ${VM_IPS}= Collections.Combine Lists ${VM_IP_NET10} ${VM_IP_NET20}
96 \ ${status} ${message} Run Keyword And Ignore Error List Should Not Contain Value ${VM_IPS} None
97 \ Exit For Loop If '${status}' == 'PASS'
99 : FOR ${vm} IN @{VM_INSTANCES_NET10} @{VM_INSTANCES_NET20}
100 \ Write Commands Until Prompt nova console-log ${vm} 30s
102 Set Suite Variable ${VM_IP_NET10}
104 Set Suite Variable ${VM_IP_NET20}
105 Should Not Contain ${VM_IP_NET10) None
106 Should Not Contain ${VM_IP_NET20} None
108 Check ELAN Datapath Traffic Within The Networks
109 [Documentation] Checks datapath within the same network with different vlans.
110 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[0]} ping -c 3 ${VM_IP_NET10[1]}
111 Should Contain ${output} 64 bytes
112 ${output} = Execute Command on VM Instance @{NETWORKS}[1] ${VM_IP_NET20[0]} ping -c 3 ${VM_IP_NET20[1]}
113 Should Contain ${output} 64 bytes
116 [Documentation] Create Router
117 Create Router ${ROUTERS[0]}
118 ${router_output} = List Router
120 Should Contain ${router_output} ${ROUTERS[0]}
121 ${router_list} = Create List ${ROUTERS[0]}
122 Wait Until Keyword Succeeds 3s 1s Check For Elements At URI ${CONFIG_API}/neutron:neutron/routers/ ${router_list}
124 Add Interfaces To Router
125 [Documentation] Add Interfaces
126 ${devstack_conn_id} = Get ControlNode Connection
127 : FOR ${INTERFACE} IN @{SUBNETS}
128 \ Add Router Interface ${ROUTERS[0]} ${INTERFACE}
129 ${interface_output} = Show Router Interface ${ROUTERS[0]}
130 : FOR ${INTERFACE} IN @{SUBNETS}
131 \ ${subnet_id} = Get Subnet Id ${INTERFACE} ${devstack_conn_id}
132 \ Should Contain ${interface_output} ${subnet_id}
134 Check L3_Datapath Traffic Across Networks With Router
135 [Documentation] Datapath test across the networks using router for L3.
136 Log Verification of FIB Entries and Flow
137 ${vm_instances} = Create List @{VM_IP_NET10} @{VM_IP_NET20}
138 Wait Until Keyword Succeeds 30s 5s Check For Elements At URI ${CONFIG_API}/odl-fib:fibEntries/ ${vm_instances}
139 Wait Until Keyword Succeeds 30s 5s Verify Flows Are Present For L3VPN ${OS_COMPUTE_1_IP} ${VM_IP_NET10}
140 Wait Until Keyword Succeeds 30s 5s Verify Flows Are Present For L3VPN ${OS_COMPUTE_1_IP} ${VM_IP_NET20}
141 Log L3 Datapath test across the networks using router
142 ${dst_ip_list} = Create List ${VM_IP_NET10[1]} @{VM_IP_NET20}
144 Test Operations From Vm Instance ${NETWORKS[0]} ${VM_IP_NET10[1]} ${dst_ip_list}
145 ${dst_ip_list} = Create List ${VM_IP_NET20[1]} @{VM_IP_NET10}
147 Test Operations From Vm Instance ${NETWORKS[1]} ${VM_IP_NET20[0]} ${dst_ip_list}
149 Add Multiple Extra Routes And Check Datapath Before L3VPN Creation
150 [Documentation] Add multiple extra routes and check data path before L3VPN creation
151 Log "Adding extra one route to VM"
152 ${CONFIG_EXTRA_ROUTE_IP1} = Catenate sudo ifconfig eth0:1 @{EXTRA_NW_IP}[0] netmask 255.255.255.0 up
153 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[0]} ${CONFIG_EXTRA_ROUTE_IP1}
154 ${CONFIG_EXTRA_ROUTE_IP2} = Catenate sudo ifconfig eth0:2 @{EXTRA_NW_IP}[1] netmask 255.255.255.0 up
155 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[0]} ${CONFIG_EXTRA_ROUTE_IP2}
156 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[0]} ifconfig
157 ${EXT_RT1} = Set Variable destination=40.1.1.0/24,nexthop=${VM_IP_NET10[0]}
158 ${EXT_RT2} = Set Variable destination=50.1.1.0/24,nexthop=${VM_IP_NET10[0]}
159 ${cmd} = Catenate ${RT_OPTIONS} ${EXT_RT1} ${EXT_RT2}
160 Update Router @{ROUTERS}[0] ${cmd}
161 Show Router @{ROUTERS}[0] -D
162 Log "Verify FIB table"
163 ${vm_instances} = Create List @{EXTRA_NW_SUBNET}
164 Wait Until Keyword Succeeds 30s 5s Check For Elements At URI ${CONFIG_API}/odl-fib:fibEntries/ ${vm_instances}
165 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[1]} ping -c 3 @{EXTRA_NW_IP}[1]
166 Should Contain ${output} 64 bytes
167 ${output} = Execute Command on VM Instance @{NETWORKS}[1] ${VM_IP_NET20[1]} ping -c 3 @{EXTRA_NW_IP}[1]
168 Should Contain ${output} 64 bytes
169 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[1]} ping -c 3 @{EXTRA_NW_IP}[0]
170 Should Contain ${output} 64 bytes
173 [Documentation] Delete the extra routes
174 Update Router @{ROUTERS}[0] ${RT_CLEAR}
175 Show Router @{ROUTERS}[0] -D
177 Delete And Recreate Extra Route
178 [Documentation] Recreate multiple extra route and check data path before L3VPN creation
179 Log "Adding extra route to VM"
180 ${CONFIG_EXTRA_ROUTE_IP1} = Catenate sudo ifconfig eth0:1 @{EXTRA_NW_IP}[0] netmask 255.255.255.0 up
181 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[0]} ${CONFIG_EXTRA_ROUTE_IP1}
182 ${EXT_RT1} = Set Variable destination=40.1.1.0/24,nexthop=${VM_IP_NET10[0]}
183 ${cmd} = Catenate ${RT_OPTIONS} ${EXT_RT1}
184 Update Router @{ROUTERS}[0] ${cmd}
185 Show Router @{ROUTERS}[0] -D
186 ${output} = Execute Command on VM Instance @{NETWORKS}[0] ${VM_IP_NET10[1]} ping -c 3 @{EXTRA_NW_IP}[0]
187 Should Contain ${output} 64 bytes
188 # clear off extra-routes before the next set of tests
189 [Teardown] Run Keywords Update Router @{ROUTERS}[0] ${RT_CLEAR}
190 ... AND Show Router @{ROUTERS}[0] -D
191 ... AND Get Test Teardown Debugs
194 [Documentation] Creates L3VPN and verify the same
195 ${devstack_conn_id} = Get ControlNode Connection
196 Switch Connection ${devstack_conn_id}
197 ${net_id} = Get Net Id @{NETWORKS}[0] ${devstack_conn_id}
198 ${tenant_id} = Get Tenant ID From Network ${net_id}
199 VPN Create L3VPN vpnid=${VPN_INSTANCE_ID[0]} name=${VPN_NAME[0]} rd=${CREATE_RD[0]} exportrt=${CREATE_EXPORT_RT[0]} importrt=${CREATE_IMPORT_RT[0]} tenantid=${tenant_id}
200 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
201 Should Contain ${resp} ${VPN_INSTANCE_ID[0]}
203 Associate L3VPN To Routers
204 [Documentation] Associating router to L3VPN
205 ${devstack_conn_id}= Get ControlNode Connection
206 ${router_id}= Get Router Id ${ROUTERS[0]} ${devstack_conn_id}
207 Associate VPN to Router routerid=${router_id} vpnid=${VPN_INSTANCE_ID[0]}
208 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
209 Should Contain ${resp} ${router_id}
211 Verify L3VPN Datapath With Router Association
212 [Documentation] Datapath test across the networks using L3VPN with router association.
213 Log Verify VPN interfaces, FIB entries and Flow table
214 ${vm_instances} = Create List @{VM_IP_NET10} @{VM_IP_NET20}
215 Wait Until Keyword Succeeds 30s 5s Check For Elements At URI ${CONFIG_API}/l3vpn:vpn-interfaces/ ${vm_instances}
216 ${RD} = Strip String ${CREATE_RD[0]} characters="[]
218 Wait Until Keyword Succeeds 60s 5s Check For Elements At URI ${CONFIG_API}/odl-fib:fibEntries/vrfTables/${RD}/ ${vm_instances}
219 Wait Until Keyword Succeeds 60s 5s Verify Flows Are Present For L3VPN ${OS_COMPUTE_1_IP} ${vm_instances}
220 Wait Until Keyword Succeeds 60s 5s Verify Flows Are Present For L3VPN ${OS_COMPUTE_2_IP} ${vm_instances}
221 Log Check datapath from network1 to network2
222 ${dst_ip_list} = Create List @{VM_IP_NET10}[1] @{VM_IP_NET20}
224 Test Operations From Vm Instance ${NETWORKS[0]} @{VM_IP_NET10}[0] ${dst_ip_list}
225 Log Check datapath from network2 to network1
226 ${dst_ip_list} = Create List @{VM_IP_NET20}[1] @{VM_IP_NET10}
228 Test Operations From Vm Instance ${NETWORKS[1]} @{VM_IP_NET20}[0] ${dst_ip_list}
230 Dissociate L3VPN From Routers
231 [Documentation] Dissociating router from L3VPN
232 ${devstack_conn_id}= Get ControlNode Connection
233 ${router_id}= Get Router Id ${ROUTERS[0]} ${devstack_conn_id}
234 Dissociate VPN to Router routerid=${router_id} vpnid=${VPN_INSTANCE_ID[0]}
235 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
236 Should Not Contain ${resp} ${router_id}
238 Delete Router And Router Interfaces With L3VPN
239 [Documentation] Delete Router and Interface to the subnets with L3VPN assciate
240 # Asscoiate router with L3VPN
241 ${devstack_conn_id} = Get ControlNode Connection
242 ${router_id}= Get Router Id ${ROUTERS[0]} ${devstack_conn_id}
243 Associate VPN to Router routerid=${router_id} vpnid=${VPN_INSTANCE_ID[0]}
244 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
245 Should Contain ${resp} ${router_id}
247 : FOR ${INTERFACE} IN @{SUBNETS}
248 \ Remove Interface ${ROUTERS[0]} ${INTERFACE}
249 ${interface_output} = Show Router Interface ${ROUTERS[0]}
250 : FOR ${INTERFACE} IN @{SUBNETS}
251 \ ${subnet_id} = Get Subnet Id ${INTERFACE} ${devstack_conn_id}
252 \ Should Not Contain ${interface_output} ${subnet_id}
253 # Delete Router and Interface to the subnets.
254 Delete Router ${ROUTERS[0]}
255 ${router_output} = List Router
257 Should Not Contain ${router_output} ${ROUTERS[0]}
258 ${router_list} = Create List ${ROUTERS[0]}
259 Wait Until Keyword Succeeds 3s 1s Check For Elements Not At URI ${CONFIG_API}/neutron:neutron/routers/ ${router_list}
260 # Verify Router Entry removed from L3VPN
261 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
262 Should Not Contain ${resp} ${router_id}
264 Delete Router With NonExistentRouter Name
265 [Documentation] Delete router with nonExistentRouter name
266 ${devstack_conn_id}= Get ControlNode Connection
267 Switch Connection ${devstack_conn_id}
268 ${output} = Write Commands Until Prompt neutron router-delete nonExistentRouter 30s
270 Should Match Regexp ${output} Unable to find router with name or id 'nonExistentRouter'|Unable to find router\\(s\\) with id\\(s\\) 'nonExistentRouter'
272 Associate L3VPN To Networks
273 [Documentation] Associates L3VPN to networks and verify
274 ${devstack_conn_id} = Get ControlNode Connection
275 ${network1_id} = Get Net Id ${NETWORKS[0]} ${devstack_conn_id}
276 ${network2_id} = Get Net Id ${NETWORKS[1]} ${devstack_conn_id}
277 Associate L3VPN To Network networkid=${network1_id} vpnid=${VPN_INSTANCE_ID[0]}
278 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
279 Should Contain ${resp} ${network1_id}
280 Associate L3VPN To Network networkid=${network2_id} vpnid=${VPN_INSTANCE_ID[0]}
281 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
282 Should Contain ${resp} ${network2_id}
284 Dissociate L3VPN From Networks
285 [Documentation] Dissociate L3VPN from networks
286 ${devstack_conn_id} = Get ControlNode Connection
287 ${network1_id} = Get Net Id ${NETWORKS[0]} ${devstack_conn_id}
288 ${network2_id} = Get Net Id ${NETWORKS[1]} ${devstack_conn_id}
289 Dissociate L3VPN From Networks networkid=${network1_id} vpnid=${VPN_INSTANCE_ID[0]}
290 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
291 Should Not Contain ${resp} ${network1_id}
292 Dissociate L3VPN From Networks networkid=${network2_id} vpnid=${VPN_INSTANCE_ID[0]}
293 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
294 Should Not Contain ${resp} ${network2_id}
297 [Documentation] Delete L3VPN
298 VPN Delete L3VPN vpnid=${VPN_INSTANCE_ID[0]}
300 Create Multiple L3VPN
301 [Documentation] Creates three L3VPNs and then verify the same
302 ${devstack_conn_id} = Get ControlNode Connection
303 Switch Connection ${devstack_conn_id}
304 ${net_id} = Get Net Id @{NETWORKS}[0] ${devstack_conn_id}
305 ${tenant_id} = Get Tenant ID From Network ${net_id}
306 VPN Create L3VPN vpnid=${VPN_INSTANCE_ID[0]} name=${VPN_NAME[0]} rd=${CREATE_RD[0]} exportrt=${CREATE_EXPORT_RT[0]} importrt=${CREATE_IMPORT_RT[0]} tenantid=${tenant_id}
307 VPN Create L3VPN vpnid=${VPN_INSTANCE_ID[1]} name=${VPN_NAME[1]} rd=${CREATE_RD[1]} exportrt=${CREATE_EXPORT_RT[1]} importrt=${CREATE_IMPORT_RT[1]} tenantid=${tenant_id}
308 VPN Create L3VPN vpnid=${VPN_INSTANCE_ID[2]} name=${VPN_NAME[2]} rd=${CREATE_RD[2]} exportrt=${CREATE_EXPORT_RT[2]} importrt=${CREATE_IMPORT_RT[2]} tenantid=${tenant_id}
309 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[0]}
310 Should Contain ${resp} ${VPN_INSTANCE_ID[0]}
311 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[1]}
312 Should Contain ${resp} ${VPN_INSTANCE_ID[1]}
313 ${resp}= VPN Get L3VPN vpnid=${VPN_INSTANCE_ID[2]}
314 Should Contain ${resp} ${VPN_INSTANCE_ID[2]}
316 Delete Multiple L3VPN
317 [Documentation] Delete three L3VPNs created using Multiple L3VPN Test
318 VPN Delete L3VPN vpnid=${VPN_INSTANCE_ID[0]}
319 VPN Delete L3VPN vpnid=${VPN_INSTANCE_ID[1]}
320 VPN Delete L3VPN vpnid=${VPN_INSTANCE_ID[2]}
322 Check Datapath Traffic Across Networks With L3VPN
323 [Documentation] Datapath Test Across the networks with VPN.
325 Log This test will be added in the next patch
328 [Documentation] Delete Vm instances in the given Instance List
329 ${VM_INSTANCES} = Create List @{VM_INSTANCES_NET10} @{VM_INSTANCES_NET20}
330 : FOR ${VmInstance} IN @{VM_INSTANCES}
331 \ Delete Vm Instance ${VmInstance}
334 [Documentation] Delete Neutron Ports in the given Port List.
335 : FOR ${Port} IN @{PORT_LIST}
336 \ Delete Port ${Port}
339 [Documentation] Delete Sub Nets in the given Subnet List.
340 : FOR ${Subnet} IN @{SUBNETS}
341 \ Delete SubNet ${Subnet}
344 [Documentation] Delete Networks in the given Net List
345 : FOR ${Network} IN @{NETWORKS}
346 \ Delete Network ${Network}
349 [Documentation] Checks that vxlan tunnels are created successfully. This testcase expects that the two DPNs are in the same network hence populates the gateway accordingly.
350 ${node_1_dpid} = Get DPID ${OS_COMPUTE_1_IP}
351 ${node_2_dpid} = Get DPID ${OS_COMPUTE_2_IP}
352 ${node_1_adapter} = Get Ethernet Adapter ${OS_COMPUTE_1_IP}
353 ${node_2_adapter} = Get Ethernet Adapter ${OS_COMPUTE_2_IP}
354 ${subnet} = Get Subnet ${OS_COMPUTE_1_IP}
355 ${gateway} = Get Default Gateway ${OS_COMPUTE_1_IP}
356 ITM Create Tunnel tunneltype=vxlan vlanid=0 prefix=${subnet} gateway=${gateway} ipaddress1=${OS_COMPUTE_1_IP} dpnid1=${node_1_dpid}
357 ... portname1=${node_1_adapter} ipaddress2=${OS_COMPUTE_2_IP} dpnid2=${node_2_dpid} portname2=${node_2_adapter}
358 Get DumpFlows And Ovsconfig ${OS_COMPUTE_1_IP}
359 Get DumpFlows And Ovsconfig ${OS_COMPUTE_2_IP}
360 ${output} = ITM Get Tunnels
364 [Documentation] Delete tunnels with specific transport-zone.
365 ITM Delete Tunnel TZA
368 Basic Vpnservice Suite Setup
369 Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
371 Basic Vpnservice Suite Teardown
374 Wait For Routes To Propogate
375 ${devstack_conn_id} = Get ControlNode Connection
376 Switch Connection ${devstack_conn_id}
377 ${net_id} = Get Net Id @{NETWORKS}[0] ${devstack_conn_id}
378 ${output} = Write Commands Until Expected Prompt sudo ip netns exec qdhcp-${net_id} ip route ]>
379 Should Contain ${output} @{SUBNET_CIDR}[0]
380 ${net_id} = Get Net Id @{NETWORKS}[1] ${devstack_conn_id}
381 ${output} = Write Commands Until Expected Prompt sudo ip netns exec qdhcp-${net_id} ip route ]>
382 Should Contain ${output} @{SUBNET_CIDR}[1]