blob: 60e39248c48ac50a439a482f5eacfee9c75c1088 [file] [log] [blame]
Sumit Naiksatam4b26d312013-01-04 10:32:54 -08001# Big Switch/FloodLight OpenFlow Controller
2# ------------------------------------------
3
4# Save trace setting
Dean Troyer8d55be32013-02-07 17:16:35 -06005MY_XTRACE=$(set +o | grep xtrace)
Sumit Naiksatam4b26d312013-01-04 10:32:54 -08006set +o xtrace
7
8BS_FL_CONTROLLERS_PORT=${BS_FL_CONTROLLERS_PORT:-localhost:80}
9BS_FL_OF_PORT=${BS_FL_OF_PORT:-6633}
10OVS_BRIDGE=${OVS_BRIDGE:-br-int}
11
12function configure_bigswitch_floodlight() {
13 :
14}
15
16function init_bigswitch_floodlight() {
17 install_quantum_agent_packages
18
19 echo -n "Installing OVS managed by the openflow controllers:"
20 echo ${BS_FL_CONTROLLERS_PORT}
21
22 # Create local OVS bridge and configure it
23 sudo ovs-vsctl --no-wait -- --if-exists del-br ${OVS_BRIDGE}
24 sudo ovs-vsctl --no-wait add-br ${OVS_BRIDGE}
25 sudo ovs-vsctl --no-wait br-set-external-id ${OVS_BRIDGE} bridge-id ${OVS_BRIDGE}
26
27 ctrls=
28 for ctrl in `echo ${BS_FL_CONTROLLERS_PORT} | tr ',' ' '`
29 do
30 ctrl=${ctrl%:*}
31 ctrls="${ctrls} tcp:${ctrl}:${BS_FL_OF_PORT}"
32 done
33 echo "Adding Network conttrollers: " ${ctrls}
34 sudo ovs-vsctl --no-wait set-controller ${OVS_BRIDGE} ${ctrls}
35}
36
37function install_bigswitch_floodlight() {
38 :
39}
40
41function start_bigswitch_floodlight() {
42 :
43}
44
45function stop_bigswitch_floodlight() {
46 :
47}
48
49# Restore xtrace
Dean Troyer8d55be32013-02-07 17:16:35 -060050$MY_XTRACE