close Warning: Can't synchronize with repository "(default)" ("(default)" is not readable or not a Git repository.). Look in the Trac log for more information.

Internal/VirtualNetwork: geniVNexperiment_6nodes.rb

File geniVNexperiment_6nodes.rb, 22.2 KB (added by ababu, 8 years ago)

Experiment (ruby file) using 6 node topology on orbit grid

Line 
1# MobilityFirst ORBIT Tutorial - Exercise 2
2# -----------------------------------------
3#
4# This script executes the performance study of the MobilityFirst
5# network protocol, outlined in Exercise 2 of the ORBIT tutorial.
6# The 4-node topology used is the following:
7#
8# Host1 ------- MFR1 ---- MFR2 ------- Host2
9#
10# The script defines software components, including the MobilityFirst
11# Router (MFR), end hosts, and the modified iperf (called mfperf), to
12# measure the performance of data transfer using the MF protocol. Host1
13# will run the mfperf (iperf modified to use MF sockets) as a client
14# and Host2 will run as the mfperf server.
15#
16# Measurement data is logged by the mfperf application using OML, and
17# can be retrieved and visualized through the OMF result service (see
18# detailed instructions in Exercise 2 of tutorial).
19
20###################
21# Apps Definition #
22###################
23
24#We need an application to enable the monitor that reports oml stats
25defApplication('MF-Router', 'router') {|app|
26 app.shortDescription = "Click-based MobilityFirst Core Router"
27 app.path = "/root/scripts/router/RWrapper.sh"
28 # click options
29 app.defProperty('num_threads', 'number of threads', "-t",{:type => :integer, :mandatory => true, :default => 4, :order => 1})
30 app.defProperty('ctrl_port', 'port for Click control socket', "-c",{:type => :string, :order => 2})
31 # click config file
32 app.defProperty('config_file', 'Click configuration file', "-C",{:type => :string,:mandatory=> true})
33 # keyword parameters used in click config file
34 app.defProperty('my_GUID', 'router GUID', "-m",{:type => :string, :mandatory => true})
35 app.defProperty('topo_file', 'path to topology file', "-f",{:type => :string, :mandatory => true})
36 app.defProperty('core_dev', 'core network interface', "-d",{:type => :string,:mandatory => true})
37 app.defProperty('GNRS_server_ip', 'IP of local GNRS server', "-s",{:type => :string,:mandatory => true})
38 app.defProperty('GNRS_server_port', 'Port of GNRS server', "-p",{:type => :string,:mandatory => true})
39 app.defProperty('GNRS_listen_ip', 'IP to listen for GNRS response', "-i",{:type => :string,:default => "0.0.0.0"})
40 app.defProperty('GNRS_listen_port', 'port to listen for GNRS response', "-P",{:type => :string,:default => "10001"})
41 app.defProperty('log_level', 'Click log level', "-l",{:type => :string,:default => "5"})
42}
43
44#We need an application to enable the monitor that reports oml stats
45defApplication('MF-Access-Router', 'access-router') {|app|
46 app.shortDescription = "Click-based MobilityFirst Access Router"
47 app.path = "/root/scripts/router/ARWrapper.sh"
48 # click options
49 app.defProperty('num_threads', 'number of threads', "-t",{:type => :integer, :mandatory => true, :default => 4, :order => 1})
50 app.defProperty('ctrl_port', 'port for Click control socket', "-c",{:type => :string, :order => 2})
51 # click config file
52 app.defProperty('config_file', 'Click configuration file', "-C",{:type => :string,:mandatory=> true})
53 # keyword parameters used in click config file
54 app.defProperty('my_GUID', 'router GUID', "-m",{:type => :string, :mandatory => true})
55 app.defProperty('topo_file', 'path to topology file', "-f",{:type => :string, :mandatory => true})
56 app.defProperty('core_dev', 'core network interface', "-d",{:type => :string,:mandatory => true})
57 app.defProperty('GNRS_server_ip', 'IP of local GNRS server', "-s",{:type => :string,:mandatory => true})
58 app.defProperty('GNRS_server_port', 'Port of GNRS server', "-p",{:type => :string,:mandatory => true})
59 app.defProperty('GNRS_listen_ip', 'IP to listen for GNRS response', "-i",{:type => :string,:default => "0.0.0.0"})
60 app.defProperty('GNRS_listen_port', 'port to listen for GNRS response', "-P",{:type => :string,:default => "10001"})
61 app.defProperty('edge_dev', 'edge network interface', "-D",{:type => :string,:mandatory => true})
62 app.defProperty('edge_dev_ip', 'IP assigned to edge interface', "-I",{:type => :string,:mandatory => true})
63 app.defProperty('virtual_topo_file', 'virtual_topo_file', "-T",{:type => :string,:mandatory => true})
64 app.defProperty('virtual_config_file', 'virtual_config_file', "-F",{:type => :string,:mandatory => true})
65 app.defProperty('virtual_service_file', 'virtual_service_file', "-S",{:type => :string,:mandatory => true})
66 app.defProperty('my_virtual_GUID', 'my_virtual_GUID', "-G",{:type => :string,:mandatory => true})
67 app.defProperty('my_virtual_network_GUID', 'my_virtual_network_GUID', "-V",{:type => :string,:mandatory => true})
68 app.defProperty('log_level', 'Click log level', "-l",{:type => :string,:default => "5"})
69}
70
71#We need an application to enable the monitor that reports oml stats
72defApplication('MF-Virtual-Router', 'virtual-router') {|app|
73 app.shortDescription = "Click-based MobilityFirst Virtual Router"
74 app.path = "/root/scripts/router/VRWrapper.sh"
75 # click options
76 app.defProperty('num_threads', 'number of threads', "-t",{:type => :integer, :mandatory => true, :default => 4, :order => 1})
77 app.defProperty('ctrl_port', 'port for Click control socket', "-c",{:type => :string, :order => 2})
78 # click config file
79 app.defProperty('config_file', 'Click configuration file', "-C",{:type => :string,:mandatory=> true})
80 # keyword parameters used in click config file
81 app.defProperty('my_GUID', 'router GUID', "-m",{:type => :string, :mandatory => true})
82 app.defProperty('topo_file', 'path to topology file', "-f",{:type => :string, :mandatory => true})
83 app.defProperty('core_dev', 'core network interface', "-d",{:type => :string,:mandatory => true})
84 app.defProperty('GNRS_server_ip', 'IP of local GNRS server', "-s",{:type => :string,:mandatory => true})
85 app.defProperty('GNRS_server_port', 'Port of GNRS server', "-p",{:type => :string,:mandatory => true})
86 app.defProperty('GNRS_listen_ip', 'IP to listen for GNRS response', "-i",{:type => :string,:default => "0.0.0.0"})
87 app.defProperty('GNRS_listen_port', 'port to listen for GNRS response', "-P",{:type => :string,:default => "10001"})
88 app.defProperty('virtual_topo_file', 'virtual_topo_file', "-T",{:type => :string,:mandatory => true})
89 app.defProperty('virtual_config_file', 'virtual_config_file', "-F",{:type => :string,:mandatory => true})
90 app.defProperty('virtual_service_file', 'virtual_service_file', "-S",{:type => :string,:mandatory => true})
91 app.defProperty('my_virtual_GUID', 'my_virtual_GUID', "-G",{:type => :string,:mandatory => true})
92 app.defProperty('my_virtual_network_GUID', 'my_virtual_network_GUID', "-V",{:type => :string,:mandatory => true})
93 app.defProperty('log_level', 'Click log level', "-l",{:type => :string,:default => "5"})
94}
95
96defApplication('MF-GNRS', 'gnrs') {|app|
97 app.shortDescription = "GNRS Server"
98 app.path = "/root/scripts/gnrs/GNRSWrapper.sh"
99 app.defProperty('log4j_config_file', 'log 4j configuration file', "-d",{:type => :string, :order => 1})
100 app.defProperty('jar_file', 'server jar file with all dependencies', "-j" ,{:type => :string, :mandatory=> true, :default => "/usr/local/src/mobilityfirst/gnrs/jserver/target/gnrs-server-1.0.0-SNAPSHOT-jar-with-dependencies.jar", :order => 2})
101 app.defProperty('config_file', 'server configuration file', "-c",{:type => :string, :mandatory=> true, :order => 3})
102}
103
104#Enable OML reporting by default
105defApplication('MF-HostStack', 'hoststack') {|app|
106 app.shortDescription = "MF host network stack"
107 app.path = "/root/scripts/client/clientWrapper.sh"
108 app.defProperty('log_level', 'log level', nil,{:type => :string, :mandatory => true, :order => 1, :default => "-d"}) # default is 'error'
109 app.defProperty('config_file', 'stack configuration file', nil,{:type => :string, :mandatory => true, :order => 2})
110}
111
112#Router monitor to report statistics
113defApplication("mf_click_monitor", "mf_click_monitor") do |app|
114 app.shortDescription = "OML enabled statistics monitor for MobilityFirst Routers"
115 app.path = "/usr/local/bin/mf_click_mon"
116 app.defProperty('ctrl_port', 'Port for Click control socket', nil,{:type => :string, :mandatory => true, :order => 1})
117 app.defProperty('self-id', 'OML ID', nil,{:type => :string, :mandatory => true, :order => 2})
118 app.defProperty('oml-config-file', 'OML configuration file', "--oml-config",{:type => :string,:mandatory=> true})
119 app.defProperty('oml-domain', 'OML domain name', "--oml-domain",{:type => :string,:mandatory=> true})
120end
121
122# defApplication('virtual-client', 'virtual-client') do |a|
123# a.path = "/root/apps/virtual-client"
124# a.version(1, 0, 0)
125# a.shortDescription = "Virtual client application for VN experiment"
126# a.description = "Virtual client application for VN experiment."
127#
128# a.defProperty('temp', 'Temp', '-m', {:type => :string})
129# end
130
131# router nodes
132# defTopology('router_universe') do |t|
133# t.addNode(baseTopo.getNodeByIndex(1))
134# t.addNode(baseTopo.getNodeByIndex(2))
135# end
136# routersTopo = Topology['router_universe']
137#
138# # host nodes
139# defTopology('host_universe') do |t|
140# t.addNode(baseTopo.getNodeByIndex(0))
141# t.addNode(baseTopo.getNodeByIndex(3))
142# end
143# hostsTopo = Topology['host_universe']
144
145#Update with data interface making sure that routers are in spoofing mode
146
147# router configurations
148#click_log_level="5"
149click_log_level="1"
150access_router_guid = ['10001', '50001']
151access_router_guid = ['10001', '50001']
152access_router_node = ['node2-20.grid.orbit-lab.org', 'node10-10.grid.orbit-lab.org']
153virtual_router_guid = []
154virtual_router_node = []
155core_router_guid = ['20002']
156core_router_node = ['node3-18.grid.orbit-lab.org']
157all_router_guid = [access_router_guid, virtual_router_guid, core_router_guid].flatten
158all_router_node = [access_router_node, virtual_router_node, core_router_node].flatten
159my_virtual_GUID_acc = ['701', '721']
160my_virtual_GUID_core = []
161router_threads = 4
162GNRS_listen_ip = '0.0.0.0'
163GNRS_listen_port = "10001"
164router_control_port = "10002"
165
166access_router_core_eth = ['192.168.2.1', '192.168.2.11']
167access_router_edge_eth = ['192.168.1.2', '192.168.3.2']
168access_router_edge_vlan = ['2001', '2003']
169core_router_core_eth = ['192.168.2.3']
170virtual_router_core_eth = []
171
172# GNRS configuration
173GNRS_server_port = "5000"
174GNRS_server_ip = '192.168.2.100'
175
176# GNRS configuration file
177GNRS_log_file = 'file:/root/conf/virtual-demo/gnrs/single-server/log4j.xml'
178GNRS_conf_file = '/root/conf/virtual-demo/gnrs/single-server/server.xml'
179GNRS_jar_file = "/usr/local/src/mobilityfirst/gnrs/jserver/target/gnrs-server-1.0.0-SNAPSHOT-jar-with-dependencies.jar"
180GNRS_nodes = ['node2-19.grid.orbit-lab.org']
181
182# host configurations
183client_guid = '1'
184client_node = 'node1-20.grid.orbit-lab.org'
185client_eth = ['192.168.1.1']
186server_guid = ['21']
187server_node = ['node10-11.grid.orbit-lab.org']
188server_eth = ['192.168.3.1']
189all_guid = [client_guid, server_guid].flatten
190all_node = [client_node, server_node].flatten
191all_eth = [client_eth, server_eth].flatten
192log_level = '-d'
193#log_level = '-e'
194
195data_netmask = '255.255.255.0'
196
197#GUID-based connectivity graph; enforced within the Click router
198rtr_topo_file = '/root/conf/virtual-demo/router/delay_test1/topology'
199virtual_topo_file = '/root/conf/virtual-demo/router/delay_test1/vtopology'
200virtual_config_file = '/root/conf/virtual-demo/router/delay_test1/vconffile'
201virtual_service_file = '/root/conf/virtual-demo/router/delay_test1/vservicefile'
202my_virtual_network_GUID = "77777"
203hoststack_conf_file = ['/root/conf/virtual-demo/client/client1.stack', '/root/conf/virtual-demo/client/server1.stack']
204
205#Click configuration file for MobilityFirst Access Router
206click_core_conf = '/usr/local/src/mobilityfirst/router/click/conf/MF_Router_GNRS.click'
207click_access_conf = '/usr/local/src/mobilityfirst/router/click/conf/MF_AccessVirtualRouter_GNRS.click'
208click_virtual_conf = '/usr/local/src/mobilityfirst/router/click/conf/MF_VirtualRouter_GNRS.click'
209
210#interface Click router listens on
211core_dev = 'eth0.2002'
212edge_dev = ['eth0.2001', 'eth0.2003']
213client_dev = ['eth0.2001', 'eth0.2003']
214
215#Create router groups
216for i in 1..access_router_guid.length
217 defTopology("topo:access_router_#{i}") { |t|
218 aNode = access_router_node[i-1]
219 t.addNode(aNode)
220 info aNode, " assigned role of access router with GUID: " + access_router_guid[i-1]
221 }
222
223 defGroup("access_router_#{i}", "topo:access_router_#{i}") {|node|
224 node.addApplication('MF-Access-Router') {|app|
225 app.setProperty('num_threads', router_threads)
226 app.setProperty('ctrl_port', router_control_port)
227 app.setProperty('config_file', click_access_conf)
228 app.setProperty('my_GUID', access_router_guid[i-1])
229 app.setProperty('topo_file', rtr_topo_file)
230 app.setProperty('core_dev', core_dev)
231 app.setProperty('GNRS_server_ip', GNRS_server_ip)
232 app.setProperty('GNRS_server_port', GNRS_server_port)
233 app.setProperty('GNRS_listen_ip', access_router_core_eth[i-1])
234 app.setProperty('GNRS_listen_port', GNRS_listen_port)
235 app.setProperty('edge_dev', edge_dev[i-1])
236 app.setProperty('edge_dev_ip', access_router_edge_eth[i-1])
237 app.setProperty('virtual_topo_file', virtual_topo_file)
238 app.setProperty('virtual_config_file', virtual_config_file)
239 app.setProperty('virtual_service_file', virtual_service_file)
240 app.setProperty('my_virtual_network_GUID', my_virtual_network_GUID)
241 app.setProperty('my_virtual_GUID', my_virtual_GUID_acc[i-1])
242 app.setProperty('log_level', click_log_level)
243 }
244
245 #Interfaces are set at run time
246 }
247end
248
249#Create router groups
250for i in 1..core_router_guid.length
251 defTopology("topo:core_router_#{i}") { |t|
252 aNode = core_router_node[i-1]
253 t.addNode(aNode)
254 info aNode, " assigned role of core router with GUID: " + core_router_guid[i-1]
255 }
256
257 defGroup("core_router_#{i}", "topo:core_router_#{i}") {|node|
258 node.addApplication('MF-Router') {|app|
259 app.setProperty('num_threads', router_threads)
260 app.setProperty('ctrl_port', router_control_port)
261 app.setProperty('config_file', click_core_conf)
262 app.setProperty('my_GUID', core_router_guid[i-1])
263 app.setProperty('topo_file', rtr_topo_file)
264 app.setProperty('core_dev', core_dev)
265 app.setProperty('GNRS_server_ip', GNRS_server_ip)
266 app.setProperty('GNRS_server_port', GNRS_server_port)
267 app.setProperty('GNRS_listen_ip', core_router_core_eth[i-1])
268 app.setProperty('GNRS_listen_port', GNRS_listen_port)
269 app.setProperty('log_level', click_log_level)
270 }
271
272 #Interfaces are set at run time
273 }
274end
275
276#Create router groups
277for i in 1..virtual_router_guid.length
278 defTopology("topo:virtual_router_#{i}") { |t|
279 aNode = virtual_router_node[i-1]
280 t.addNode(aNode)
281 info aNode, " assigned role of virtual router with GUID: " + virtual_router_guid[i-1]
282 }
283
284 defGroup("virtual_router_#{i}", "topo:virtual_router_#{i}") {|node|
285 node.addApplication('MF-Virtual-Router') {|app|
286 app.setProperty('num_threads', router_threads)
287 app.setProperty('ctrl_port', router_control_port)
288 app.setProperty('config_file', click_virtual_conf)
289 app.setProperty('my_GUID', virtual_router_guid[i-1])
290 app.setProperty('topo_file', rtr_topo_file)
291 app.setProperty('core_dev', core_dev)
292 app.setProperty('GNRS_server_ip', GNRS_server_ip)
293 app.setProperty('GNRS_server_port', GNRS_server_port)
294 app.setProperty('GNRS_listen_ip', virtual_router_core_eth[i-1])
295 app.setProperty('GNRS_listen_port', GNRS_listen_port)
296 app.setProperty('virtual_topo_file', virtual_topo_file)
297 app.setProperty('virtual_config_file', virtual_config_file)
298 app.setProperty('virtual_service_file', virtual_service_file)
299 app.setProperty('my_virtual_network_GUID', my_virtual_network_GUID)
300 app.setProperty('my_virtual_GUID', my_virtual_GUID_core[i-1])
301 app.setProperty('log_level', click_log_level)
302 }
303
304 #Interfaces are set at run time
305 }
306end
307
308for i in 1..GNRS_nodes.length
309 defTopology("topo:gnrs_#{i}") { |t|
310 aNode = GNRS_nodes[i-1]
311 t.addNode(aNode)
312 info aNode, " assigned role of GNRS"
313 }
314
315 defGroup("gnrs_#{i}", "topo:gnrs_#{i}") {|node|
316 node.addApplication('MF-GNRS') {|app|
317 app.setProperty('log4j_config_file', GNRS_log_file)
318 app.setProperty('jar_file', GNRS_jar_file)
319 app.setProperty('config_file', GNRS_conf_file)
320 }
321 }
322end
323
324#Create host groups
325for i in 1..all_node.length
326 defTopology("topo:host_#{i}") { |t|
327 aNode = all_node[i-1]
328 t.addNode(aNode)
329 info aNode, " assigned role of client with GUID: " + all_guid[i-1]
330 }
331
332 defGroup("host_#{i}", "topo:host_#{i}") {|node|
333 node.addApplication('MF-HostStack') {|app|
334 app.setProperty('config_file', hoststack_conf_file[i-1])
335 app.setProperty('log_level', log_level)
336 }
337
338 #setup interfaces at run time
339 }
340end
341
342oml_config_file = "/root/conf/virtual-demo/router/click-oml-config.xml"
343oml_domain = "geni22VNdemo"
344
345#Create router groups
346for i in 1..all_router_guid.length
347 defTopology("topo:router_monitor_#{i}") { |t|
348 aNode = all_router_node[i-1]
349 t.addNode(aNode)
350 info aNode, " started monitor for guid: " + all_router_guid[i-1]
351 }
352
353 defGroup("router_monitor_#{i}", "topo:router_monitor_#{i}") {|node|
354 node.addApplication('mf_click_monitor') {|app|
355 app.setProperty('ctrl_port', router_control_port)
356 app.setProperty('self-id', all_router_guid[i-1])
357 app.setProperty('oml-config-file', oml_config_file)
358 app.setProperty('oml-domain', oml_domain)
359 }
360 }
361end
362
363# # Configure mfperf client
364# defTopology("topo:mfperf_client") { |t|
365# aNode = hostsTopo.getNodeByIndex(0)
366# t.addNode(aNode)
367# print "Adding node: ", aNode, " as mfperf_client\n"
368# }
369# defGroup("mfperf_client", "topo:mfperf_client") {|node|
370# node.addApplication('mfperf') {|app|
371# app.setProperty('mode', 'client')
372# app.setProperty('chunk_size', mfperf_initial_chunk_size)
373# app.setProperty('data_rate', mfperf_initial_data_rate)
374# }
375# }
376#
377# # Configure mfperf server
378# defTopology("topo:mfperf_server") { |t|
379# aNode = hostsTopo.getNodeByIndex(1)
380# t.addNode(aNode)
381# print "Adding node: ", aNode, " as mfperf_server\n"
382# }
383# defGroup("", "mf:topo:mfperf_server") {|node|
384# node.addApplication('mfperf') {|app|
385# app.setProperty('mode', 'server')
386# app.setProperty('chunk_size', mfperf_initial_chunk_size)
387# app.setProperty('data_rate', mfperf_initial_data_rate)
388# }
389# }
390
391info 'Definition of resources completed'
392
393onEvent(:ALL_UP_AND_INSTALLED) do |event|
394
395 info "Initializing resources"
396 # clean up and initialize networking for routers
397 for i in 1..access_router_node.length
398 info "Preparing resources on node " + access_router_node[i-1]
399 # click router cleanup
400 group("access_router_#{i}").exec("killall -9 click")
401 group("access_router_#{i}").exec("killall -9 mf_click_mon")
402 #setup interfaces
403 group("access_router_#{i}").exec("ifconfig " + core_dev + " " + access_router_core_eth[i-1] + " netmask 255.255.255.0")
404 group("access_router_#{i}").exec("ifconfig " + core_dev + " up")
405 #setup interfaces
406 group("access_router_#{i}").exec("ifconfig " + edge_dev[i-1] + " " + access_router_edge_eth[i-1] + " netmask 255.255.255.0")
407 group("access_router_#{i}").exec("ifconfig " + edge_dev[i-1] + " up")
408 end
409 # clean up and initialize networking for routers
410 for i in 1..core_router_node.length
411 info "Preparing resources on node " + core_router_node[i-1]
412 # click router cleanup
413 group("core_router_#{i}").exec("killall -9 click")
414 group("core_router_#{i}").exec("killall -9 mf_click_mon")
415 #setup interfaces
416 group("core_router_#{i}").exec("ifconfig " + core_dev + " " + core_router_core_eth[i-1] + " netmask 255.255.255.0")
417 group("core_router_#{i}").exec("ifconfig " + core_dev + " up")
418 end
419 # clean up and initialize networking for routers
420 for i in 1..virtual_router_node.length
421 info "Preparing resources on node " + virtual_router_node[i-1]
422 # click router cleanup
423 group("virtual_router_#{i}").exec("killall -9 click")
424 group("virtual_router_#{i}").exec("killall -9 mf_click_mon")
425 #setup interfaces
426 group("virtual_router_#{i}").exec("ifconfig " + core_dev + " " + virtual_router_core_eth[i-1] + " netmask 255.255.255.0")
427 group("virtual_router_#{i}").exec("ifconfig " + core_dev + " up")
428 end
429
430 #clean up and initialize networking for hosts
431 for i in 1..all_node.length
432 info "Preparing resources on node " + all_node[i-1]
433 group("host_#{i}").exec("killall -9 mfstack")
434 #setup interfaces
435 group("host_#{i}").exec("ifconfig " + client_dev[i-1] + " " + all_eth[i-1] + " netmask 255.255.255.0")
436 group("host_#{i}").exec("ifconfig " + client_dev[i-1] + " up")
437 end
438
439 #clean up and initialize networking for hosts
440 for i in 1..GNRS_nodes.length
441 info "Preparing resources on node " + GNRS_nodes[i-1]
442 group("gnrs_#{i}").exec("killall -9 java")
443 group("gnrs_#{i}").exec("rm -r /tmp/bdb/")
444 #setup interfaces
445 group("gnrs_#{i}").exec("ifconfig " + core_dev + " " + GNRS_server_ip + " netmask 255.255.255.0")
446 group("gnrs_#{i}").exec("ifconfig " + core_dev + " up")
447 end
448
449 wait 10
450
451 for i in 1..GNRS_nodes.length
452 info "Starting GNRS on node " + GNRS_nodes[i-1]
453 group("gnrs_#{i}").startApplications
454 end
455
456 # bring up routers (along with gnrs servers)
457 info "Bringing up routers..."
458 for i in 1..access_router_node.length
459 info "Starting router " + access_router_guid[i-1] + " on node " + access_router_node[i-1]
460 # click router cleanup
461 group("access_router_#{i}").startApplications
462 end
463 for i in 1..core_router_node.length
464 info "Starting router " + core_router_node[i-1] + " on node " + core_router_node[i-1]
465 # click router cleanup
466 group("core_router_#{i}").startApplications
467 end
468 for i in 1..virtual_router_node.length
469 info "Starting router " + virtual_router_node[i-1] + " on node " + virtual_router_node[i-1]
470 # click router cleanup
471 group("virtual_router_#{i}").startApplications
472 end
473 wait 5
474
475 info "Bringing up host stacks..."
476 for i in 1..all_node.length
477 info "Starting hoststack " + all_guid[i-1] + " on node " + all_node[i-1]
478 group("host_#{i}").startApplications
479 end
480
481 #Starting router monitors
482 for i in 1..all_router_guid.length
483 info "Starting monitor for router " + all_router_guid[i-1]
484 group("router_monitor_#{i}").startApplications
485 end
486
487 info "Press to Ctrl-C to kill the experiment"
488 while true
489 wait 10
490 end
491
492 Experiment.done
493end