2 Documentation Test suite for Cluster HA - Device Owner Stop and Start
3 Suite Setup SetupUtils.Setup_Utils_For_Setup_And_Teardown
4 Suite Teardown Delete All Sessions
5 Library RequestsLibrary
6 Resource ../../../libraries/SetupUtils.robot
7 Resource ../../../libraries/ClusterOpenFlow.robot
8 Resource ../../../libraries/MininetKeywords.robot
9 Resource ../../../libraries/ClusterManagement.robot
10 Variables ../../../variables/Variables.py
13 Check Shards Status Before Stop
14 [Documentation] Check Status for all shards in OpenFlow application.
15 ClusterOpenFlow.Check OpenFlow Shards Status
17 Start Mininet Multiple Connections
18 [Documentation] Start mininet tree,2 with connection to all cluster instances.
19 ${mininet_conn_id}= MininetKeywords.Start Mininet Multiple Controllers ${TOOLS_SYSTEM_IP} ${ClusterManagement__member_index_list} --topo tree,2
20 BuiltIn.Set Suite Variable ${mininet_conn_id}
21 BuiltIn.Wait Until Keyword Succeeds 10s 1s OVSDB.Check OVS OpenFlow Connections ${TOOLS_SYSTEM_IP} 9
23 Check Entity Owner Status And Find Owner and Successor Before Stop
24 [Documentation] Check Entity Owner Status and identify owner and successor for first switch s1.
25 ${original_owner} ${original_successor_list} ClusterOpenFlow.Get OpenFlow Entity Owner Status For One Device openflow:1 1
26 ${original_successor}= Collections.Get From List ${original_successor_list} 0
27 BuiltIn.Set Suite Variable ${original_owner}
28 BuiltIn.Set Suite Variable ${original_successor_list}
29 BuiltIn.Set Suite Variable ${original_successor}
31 Reconnect Extra Switches To Successors And Check OVS Connections
32 [Documentation] Connect switches s2 and s3 to successor instances.
33 ${controller_opt} = BuiltIn.Set Variable
34 : FOR ${index} IN @{original_successor_list}
35 \ ${controller_opt} = BuiltIn.Catenate ${controller_opt} ${SPACE}tcp:${ODL_SYSTEM_${index}_IP}:${ODL_OF_PORT}
36 \ Log ${controller_opt}
37 OVSDB.Set Controller In OVS Bridge ${TOOLS_SYSTEM_IP} s2 ${controller_opt}
38 OVSDB.Set Controller In OVS Bridge ${TOOLS_SYSTEM_IP} s3 ${controller_opt}
39 BuiltIn.Wait Until Keyword Succeeds 10s 1s OVSDB.Check OVS OpenFlow Connections ${TOOLS_SYSTEM_IP} 7
41 Check Network Operational Information Before Stop
42 [Documentation] Check devices in operational inventory and topology in all cluster instances.
43 ClusterOpenFlow.Check OpenFlow Network Operational Information For Sample Topology
45 Add Configuration In Owner and Verify Before Stop
46 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
47 ClusterOpenFlow.Add Sample Flow and Verify ${original_owner}
49 Modify Configuration In Owner and Verify Before Stop
50 [Documentation] Modify Flow in Owner and verify it gets applied from all instances.
51 ClusterOpenFlow.Modify Sample Flow and Verify ${original_owner}
53 Delete Configuration In Owner and Verify Before Stop
54 [Documentation] Delete Flow in Owner and verify it gets applied from all instances.
55 ClusterOpenFlow.Delete Sample Flow and Verify ${original_owner}
57 Add Configuration In Successor and Verify Before Stop
58 [Documentation] Add Flow in Successor and verify it gets applied from all instances.
59 ClusterOpenFlow.Add Sample Flow and Verify ${original_successor}
61 Modify Configuration In Successor and Verify Before Stop
62 [Documentation] Modify Flow in successor and verify it gets applied from all instances.
63 ClusterOpenFlow.Modify Sample Flow and Verify ${original_successor}
65 Delete Configuration In Successor and Verify Before Stop
66 [Documentation] Delete Flow in Successor and verify it gets removed from all instances.
67 ClusterOpenFlow.Delete Sample Flow and Verify ${original_successor}
69 Send RPC Add to Owner and Verify Before Stop
70 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
71 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${original_owner}
73 Send RPC Delete to Owner and Verify Before Stop
74 [Documentation] Delete Flow in Owner and verify it gets removed from all instances.
75 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${original_owner}
77 Send RPC Add to Successor and Verify Before Stop
78 [Documentation] Add Flow in Successor and verify it gets applied from all instances.
79 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${original_successor}
81 Send RPC Delete to Successor and Verify Before Stop
82 [Documentation] Delete Flow in Successor and verify it gets removed from all instances.
83 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${original_successor}
85 Modify Network And Verify Before Stop
86 [Documentation] Take a link down and verify port status in all instances.
87 ClusterOpenFlow.Take OpenFlow Device Link Down and Verify
89 Restore Network And Verify Before Stop
90 [Documentation] Take the link up and verify port status in all instances.
91 ClusterOpenFlow.Take OpenFlow Device Link Up and Verify
94 [Documentation] Stop Owner Instance and verify it is dead
95 ClusterManagement.Stop Single Member ${original_owner}
96 BuiltIn.Set Suite Variable ${new_cluster_list} ${original_successor_list}
98 Check Shards Status After Stop
99 [Documentation] Create original cluster list and check Status for all shards in OpenFlow application.
100 ClusterOpenFlow.Check OpenFlow Shards Status After Cluster Event ${new_cluster_list}
102 Check Entity Owner Status And Find Owner and Successor After Stop
103 [Documentation] Check Entity Owner Status and identify owner and successor.
104 ${new_owner} ${new_successor_list} ClusterOpenFlow.Get OpenFlow Entity Owner Status For One Device openflow:1 ${original_successor} ${new_cluster_list} after_stop=True
105 ${new_successor}= Collections.Get From List ${new_successor_list} 0
106 BuiltIn.Set Suite Variable ${new_owner}
107 BuiltIn.Set Suite Variable ${new_successor}
109 Check Network Operational Information After Stop
110 [Documentation] Check devices in operational inventory and topology in all cluster instances.
111 ClusterOpenFlow.Check OpenFlow Network Operational Information For Sample Topology ${new_cluster_list}
113 Add Configuration In Owner and Verify After Stop
114 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
115 ClusterOpenFlow.Add Sample Flow and Verify ${new_owner} ${new_cluster_list}
117 Modify Configuration In Owner and Verify After Stop
118 [Documentation] Modify Flow in Owner and verify it gets applied from all instances.
119 ClusterOpenFlow.Modify Sample Flow and Verify ${new_owner} ${new_cluster_list}
121 Delete Configuration In Owner and Verify After Stop
122 [Documentation] Delete Flow in Owner and verify it gets applied from all instances.
123 ClusterOpenFlow.Delete Sample Flow and Verify ${new_owner} ${new_cluster_list}
125 Add Configuration In Successor and Verify After Stop
126 [Documentation] Add Flow in Successor and verify it gets applied from all instances.
127 ClusterOpenFlow.Add Sample Flow and Verify ${new_successor} ${new_cluster_list}
129 Modify Configuration In Successor and Verify After Stop
130 [Documentation] Modify Flow in Successor and verify it gets applied from all instances.
131 ClusterOpenFlow.Modify Sample Flow and Verify ${new_successor} ${new_cluster_list}
133 Delete Configuration In Successor and Verify After Stop
134 [Documentation] Delete Flow in Successor and verify it gets applied from all instances.
135 ClusterOpenFlow.Delete Sample Flow and Verify ${new_successor} ${new_cluster_list}
137 Send RPC Add to Owner and Verify After Stop
138 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
139 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${new_owner} ${new_cluster_list}
141 Send RPC Delete to Owner and Verify After Stop
142 [Documentation] Delete Flow in Owner and verify it gets removed from all instances.
143 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${new_owner} ${new_cluster_list}
145 Send RPC Add to Successor and Verify After Stop
146 [Documentation] Add Flow in Successor and verify it gets applied from all instances.
147 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${new_successor} ${new_cluster_list}
149 Send RPC Delete to Successor and Verify After Stop
150 [Documentation] Delete Flow in Successor and verify it gets removed from all instances.
151 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${new_successor} ${new_cluster_list}
153 Modify Network and Verify After Stop
154 [Documentation] Take a link down and verify port status in all instances.
155 ClusterOpenFlow.Take OpenFlow Device Link Down and Verify ${new_cluster_list}
157 Restore Network and Verify After Stop
158 [Documentation] Take the link up and verify port status in all instances.
159 ClusterOpenFlow.Take OpenFlow Device Link Up and Verify ${new_cluster_list}
161 Start Old Owner Instance
162 [Documentation] Start old Owner Instance and verify it is up
163 ClusterManagement.Start Single Member ${original_owner}
165 Check Shards Status After Start
166 [Documentation] Create original cluster list and check Status for all shards in OpenFlow application.
167 ClusterOpenFlow.Check OpenFlow Shards Status After Cluster Event
169 Check Entity Owner Status After Start
170 [Documentation] Check Entity Owner Status and identify owner and successor.
171 ${new_owner} ${new_successors_list} ClusterOpenFlow.Get OpenFlow Entity Owner Status For One Device openflow:1 1
172 BuiltIn.Set Suite Variable ${new_owner}
174 Check Network Operational Information After Start
175 [Documentation] Check devices in operational inventory and topology in all cluster instances.
176 ClusterOpenFlow.Check OpenFlow Network Operational Information For Sample Topology
178 Add Configuration In Owner and Verify After Start
179 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
180 ClusterOpenFlow.Add Sample Flow and Verify ${new_owner}
182 Modify Configuration In Owner and Verify After Start
183 [Documentation] Modify Flow in Owner and verify it gets applied from all instances.
184 ClusterOpenFlow.Modify Sample Flow and Verify ${new_owner}
186 Delete Configuration In Owner and Verify After Start
187 [Documentation] Delete Flow in Owner and verify it gets applied from all instances.
188 ClusterOpenFlow.Delete Sample Flow and Verify ${new_owner}
190 Add Configuration In Old Owner and Verify After Start
191 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
192 ClusterOpenFlow.Add Sample Flow and Verify ${original_owner}
194 Modify Configuration In Old Owner and Verify After Start
195 [Documentation] Modify Flow in Owner and verify it gets applied from all instances.
196 ClusterOpenFlow.Modify Sample Flow and Verify ${original_owner}
198 Delete Configuration In Old Owner and Verify After Start
199 [Documentation] Delete Flow in Owner and verify it gets applied from all instances.
200 ClusterOpenFlow.Delete Sample Flow and Verify ${original_owner}
202 Send RPC Add to Owner and Verify After Start
203 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
204 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${new_owner}
206 Send RPC Delete to Owner and Verify After Start
207 [Documentation] Delete Flow in Owner and verify it gets removed from all instances.
208 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${new_owner}
210 Send RPC Add to Old Owner and Verify After Start
211 [Documentation] Add Flow in Owner and verify it gets applied from all instances.
212 ClusterOpenFlow.Send RPC Add Sample Flow and Verify ${original_owner}
214 Send RPC Delete to Old Owner and Verify After Start
215 [Documentation] Delete Flow in Owner and verify it gets removed from all instances.
216 ClusterOpenFlow.Send RPC Delete Sample Flow and Verify ${original_owner}
218 Modify Network and Verify After Start
219 [Documentation] Take a link down and verify port status in all instances.
220 ClusterOpenFlow.Take OpenFlow Device Link Down and Verify
222 Restore Network and Verify After Start
223 [Documentation] Take the link up and verify port status in all instances.
224 ClusterOpenFlow.Take OpenFlow Device Link Up and Verify
226 Stop Mininet and Exit
227 [Documentation] Stop mininet and exit connection.
228 MininetKeywords.Stop Mininet And Exit ${mininet_conn_id}
229 Utils.Clean Mininet System
231 Check No Network Operational Information
232 [Documentation] Check device is not in operational inventory or topology in all cluster instances.
233 ClusterOpenFlow.Check No OpenFlow Network Operational Information