-
Notifications
You must be signed in to change notification settings - Fork 17
Run the whole Odin scenario
[UNDER CONSTRUCTION]
This assumes you have run all the previous steps, so you have installed the controller, and a number of agents.
If you have followed the instructions to Install and test Odin controller, you just have to run:
~/odin-controller# java -jar ./target/floodlight.jar -cf ./src/main/resources/floodlightdefault.properties
The controller will start and wait for connections.
As we are going to disable the internal DHCP server of all the APs (this is required by Odin), you have to install a DHCP server in a machine (it should not be the same machine where the Odin controller is running).
For example, in Debian, you can install the package (https://wiki.debian.org/DHCP_Server):
$ apt-get install isc-dhcp-server
The main configuration file for a dhcp server is /etc/dhcp/dhcpd.conf
The interface where DHCP server is hearing is defined in /etc/default/isc-dhcp-server
INTERFACES=”eth0”
Start and stop it:
$ /etc/init.d/isc-dhcp-server start
$ /etc/init.d/isc-dhcp-server stop
$ /etc/init.d/isc-dhcp-server status
You shoud see:
Status of ISC DHCP server: dhcpd is running.
Note. The DHCP server of the agents (APs) must be disabled. For example, you can do that with Luci (web server of each AP). Go to Network / Interfaces / Eth1.1 / Disable DHCP for this interface
.
Use the file agent-click-file-gen.py
to generate the .cli file required by the agent
Configure and use this script to generate the appropriate Odin agent click file.
This is an example of how to use the python command:
$ python agent-click-file-gen.py 4 50 14:CC:20:AC:72:91 192.168.1.129 2819 /sys/kernel/debug/ieee80211/phy0/ath9k/bssid_extra odin-unizar 192.168.1.7 0 11 12 25 0
where the parameters have the next meaning:
4
number of the channel
50
size of the queue
14:CC:20:AC:72:91
MAC address of the AP
192.168.1.129
IP address of the Controller
2819
port used to connect with the Controller
/sys/kernel/debug/ieee80211/phy0/ath9k/bssid_extra
directory of the debug file
odin-unizar
SSID
192.168.1.7
IP address of the AP
0
No click debug info
11
Debug level 1, with Demo appearance (1)
12
6 Mbps of TX rate
25
the Tx power of the AP is 25 dBm (obtained with $iw dev mon0 info
)
`0 no hidden mode: the AP will respond to all active scanning requests, even if they have no SSID name
The file is generated, but it has to be aligned before being used in the AP. Use the click-align tool you have generated before, for that aim:
$: click-align agent.cli > aagent.cli
Move the aagent.cli
file generated to the AP. If there is no place in the main memory of the wireless router, you may need to use a external USB unit /mt/usb/
.
You can use the script start.sh to automate these things:
- preparing the interfaces
- starting OpenvSwitch
- start Click
- add some OpenFlow rules to the local switch
Tune the parameters of the script (IP addresses, ports, locations of files, etc.) and run it.
At this point, you should be able to connect from a STA and ping. You should see an ESSID created by Odin in the STA. You can connect in Linux using:
$ iwconfig wlan0 essid odin-ssid
If you are here, congratulations!