blob: e3f4689fd7696653b1f83c3b4a4ee5db89176045 [file] [log] [blame]
Sean Daguee263c822014-12-05 14:25:28 -05001#!/bin/bash
2#
Sumit Naiksatam4b26d312013-01-04 10:32:54 -08003# Big Switch/FloodLight OpenFlow Controller
4# ------------------------------------------
5
6# Save trace setting
Dean Troyere3a91602014-03-28 12:40:56 -05007BS3_XTRACE=$(set +o | grep xtrace)
Sumit Naiksatam4b26d312013-01-04 10:32:54 -08008set +o xtrace
9
10BS_FL_CONTROLLERS_PORT=${BS_FL_CONTROLLERS_PORT:-localhost:80}
11BS_FL_OF_PORT=${BS_FL_OF_PORT:-6633}
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080012
Ian Wienandaee18c72014-02-21 15:35:08 +110013function configure_bigswitch_floodlight {
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080014 :
15}
16
Ian Wienandaee18c72014-02-21 15:35:08 +110017function init_bigswitch_floodlight {
Mark McClainb05c8762013-07-06 23:29:39 -040018 install_neutron_agent_packages
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080019
20 echo -n "Installing OVS managed by the openflow controllers:"
21 echo ${BS_FL_CONTROLLERS_PORT}
22
23 # Create local OVS bridge and configure it
24 sudo ovs-vsctl --no-wait -- --if-exists del-br ${OVS_BRIDGE}
25 sudo ovs-vsctl --no-wait add-br ${OVS_BRIDGE}
26 sudo ovs-vsctl --no-wait br-set-external-id ${OVS_BRIDGE} bridge-id ${OVS_BRIDGE}
27
28 ctrls=
Sean Dague16dd8b32014-02-03 09:10:54 +090029 for ctrl in `echo ${BS_FL_CONTROLLERS_PORT} | tr ',' ' '`; do
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080030 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
Ian Wienandaee18c72014-02-21 15:35:08 +110037function install_bigswitch_floodlight {
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080038 :
39}
40
Ian Wienandaee18c72014-02-21 15:35:08 +110041function start_bigswitch_floodlight {
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080042 :
43}
44
Ian Wienandaee18c72014-02-21 15:35:08 +110045function stop_bigswitch_floodlight {
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080046 :
47}
48
Ian Wienandaee18c72014-02-21 15:35:08 +110049function check_bigswitch_floodlight {
armando-migliaccioef1e0802014-01-02 16:33:53 -080050 :
51}
52
Sumit Naiksatam4b26d312013-01-04 10:32:54 -080053# Restore xtrace
Dean Troyere3a91602014-03-28 12:40:56 -050054$BS3_XTRACE