-
Notifications
You must be signed in to change notification settings - Fork 0
Infocom 2016 Demo
| Machine | Networks | SSH Shortcut | BSSID | Other |
|---|---|---|---|---|
| Controller VM | eth1: 10.10.10.210/24 eth0: DHCP (VBox NAT) |
- | - | - |
| LED Controller | 10.10.10.199/24 | - | - | DHCP from VM only for MAC ac:cf:23:28:a3:f2
|
| AP1: green01 | 10.10.10.1/24 | green01 | b8:27:eb:70:6d:75 | U: root P: gr33ntouch |
| AP2: green02 | 10.10.10.2/24 | green02 | b8:27:eb:ee:b5:df | U: root P: gr33ntouch |
| AP3: green03 | 10.10.10.3/24 | green03 | b8:27:eb:fe:dd:24 | U: root P: gr33ntouch |
| UE1 (Sandy) | 10.10.10.11/24 | - | - | - |
| UE1 (Chantal) | 10.10.10.12/24 | - | - | (optional) |
The VM now has two network interfaces. One configured as VirtualBox NAT adapter to have a internet connection to the outside and one configured as VirtualBox bridge adapter to be connected to the local testbed network.
Note: Not sure what happens when importing the VM! It may be necessary to redo these VirtualBox configurations.
- eth0: NAT DHCP from VirtualBox host (to have a internet connection)
- eth1: Bridged to host interface connected to testbed (static: 10.10.10.210/24)
The following section describes the setup of the access points. Each of them is a normal PC (or RPi) with hostapd running on it in bridge mode (layer 2 bridge to ethernet interface). These access points do not provide any special functionality.
- SSID: BCG2Demo
- PSK: gr33ntouch
Some resources about setting up hostapd:
/ets/hostapd/hostapd.conf
# specify the wifi interface
interface=wlan0
driver=nl80211
# specify the bridge interface for bridge operation
bridge=bridge0
country_code=DE
ieee80211d=1
ssid=BCG2Demo
hw_mode=g
channel=1
wme_enabled=0
# Station MAC address -based authentication
# Please note that this kind of access control requires a driver that uses
# hostapd to take care of management frame processing and as such, this can be
# used with driver=hostap or driver=nl80211, but not with driver=madwifi.
# 0 = accept unless in deny list
# 1 = deny unless in accept list
# 2 = use external RADIUS server (accept/deny lists are searched first)
macaddr_acl=0
# Accept/deny lists are read from separate files (containing list of
# MAC addresses, one per line). Use absolute path name to make sure that the
# files can be read on SIGHUP configuration reloads.
#accept_mac_file=/etc/hostapd/mac.accept
#deny_mac_file=/etc/hostapd/mac.deny
auth_algs=1
wpa=2
wpa_passphrase=gr33ntouch
wpa_key_mgmt=WPA-PSK
wpa_pairwise=TKIP
rsn_pairwise=CCMP
ctrl_interface=/var/run/hostapd
ctrl_interface_group=0
logger_syslog=-1
logger_syslog_level=1
logger_stdout=-1
logger_stdout_level=1
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet manual
auto wlan0
iface wlan0 inet manual
auto bridge
iface bridge inet static
bridge_ports eth0 wlan0
address 10.10.10.1
netmask 255.255.255.0
gateway 10.10.10.210
Our controller needs a SSH connection to each AP to obtain traffic data from it. For this, the following key has to be added into .ssh/autorized_keysfile on each AP. The controller VM is configured (.ssh/config) to have SSH shortcuts green01- green03to connect to the APs.
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC9avqGL22oIccihw5ikQOIU6q5WG/loBvQbc5ziMzoYWgXbLK9NIuLXU/C1RtnHn7vfkUy+4lV9Kq08s3FPrHxPic10PnyUrO+YMs0whn4ZqD4Og6x9alnuxwd9GApee0gNdWZ5SeBL721x6cpdj3QOOM+/3fREzf7wHjZsv0Cpg6DXqRYsEcgjTqkqF1ubgggH67CtlnVo/sBX6tkdJm8rqWbQ01DisMLSTE2Bk9MmPWCyEgj3psYSzE8tmMAKzOcDsSTZho/tzjx8HgrwHrEW55a2GFhUbyQv9jeiPSswFPIC4jakl1/Lg6zQqHkPcrTln8+jteUfcqlFx4hgPTt greentouch@greentouch-VirtualBox
The following steps describe how to test if the new access points work together with UPB's access point manger. Before doing these tests, check if the APs are reachable from the controller VM: ping 10.10.10.1 - 3.
cd Desktop/BCG_DEMO/mt_backend/ap_managerpython upb_apmanager.py -v -l debug -a start -c config_infocom.json
Start a second terminal and check the REST API of the access point manager:
-
curl 127.0.0.1:6682/api/network/accesspoint -
Response:
{"offline": [], "online": ["e60db822c51d330bbf6954f306941678", "c3b4a156913a37bf8e11e0bf756fcd9f", "dd8a05d9212131dcbb531ffc5cdd3979"]} -
curl 127.0.0.1:6682/api/network/accesspoint/e60db822c51d330bbf6954f306941678/info -
Response:
{"state": "online", "uuid": "e60db822c51d330bbf6954f306941678", "serial": "00156195a7c1", "name": "green01"} -
curl 127.0.0.1:6682/api/network/accesspoint/e60db822c51d330bbf6954f306941678/stats -
Response:
{"aps": [{"txbyte": 748644, "name": "wlan0", "rxbyte": 353270, "timestamp": 1457093744.035127, "txpkt": 0, "rxpkt": 0}]}
The following steps describe how you can test the setup without having a real smartphone connected to the system.
./init_demo.sh- Start the GUI
- Run:
python mt_backend/misc/dev_client.py
A IPython console comes up. Enter the following commands to register some UEs and trigger a random update mechanism:
UE.register()RU.run()
This will randomly update the UE location/traffic data until you abort it.
The controller VM contains a preconfigured port forwarding script that connects to peu-srv.de and listens to port 6680 for incoming connections from the UE application.
- run:
./start_ssh_portforewarding.shand keep the terminal window open
- Start VM
- Check network connectivity
- APs:
ping 10.10.10.1-ping 10.10.10.3 - LED ctrl:
ping 10.10.10.199 - Internet:
ping www.peu-srv.de - (can also be done with ./check.sh in BCG_DEMO) 2.5 Check SSH connectivity:
ssh green01ssh green02ssh green03
- Start port forwarding:
./start_ssh_portforewarding.sh(keep open) - Start iperf server:
./start_ssh_portforewarding.sh(keep open) - Start IP forwarding:
sudo ./start_ip_forwarding.sh(keep open) - Initialize demo (localization, controller, ...):
./init_demo.sh - Run POLIMI GUI: Eclipse -> Run -> Laura Manager
- (optional) Run UPB Web-GUI: Desktop -> UPB Dashboard (connect button top-right)
-
./init_demo.sh: ./jetty not found! This was the MobiMESH controller? Shouldn't be a problem, right? - ...