cluster-lab icon indicating copy to clipboard operation
cluster-lab copied to clipboard

Is it possible for Cluster Lab on wlan0 instead of eth0?

Open oktak opened this issue 9 years ago • 3 comments

Hello, I've followed the instructions in this Hypriot Blog Post. Could that be setup Cluster Lab using Pi 3's wifi chip instead of using eth0 (Ethernet)?

I tried to edit /etc/cluster-lab/cluster.conf manually. When I cluster-lab stop and then start. It shows me:

Got more than one IP address on wlan0.200: 192.168.200.1

Is that a bad idea to build a cluster using wlan? If not, how to config Cluster Lab on the Pi 3? Thanks!

oktak avatar Jul 31 '16 12:07 oktak

@firecyberice Can you guide @oktak through this?

Govinda-Fichtner avatar Aug 02 '16 05:08 Govinda-Fichtner

@oktak You just need to change these three parameters:

  • https://github.com/hypriot/cluster-lab/blob/master/package/etc/cluster-lab/cluster.conf#L9
  • https://github.com/hypriot/cluster-lab/blob/master/package/etc/cluster-lab/cluster.conf#L13 (wlan does not support vlan)
  • https://github.com/hypriot/cluster-lab/blob/master/package/etc/cluster-lab/cluster.conf#L20 (assuming that your wifi network already has a dhcp server)

firecyberice avatar Aug 02 '16 06:08 firecyberice

Thanks for @firecyberice help. I got cluster-lab health all [PASS] now :D

Here is my journey: Before I open an issue here, I used --clusterlab true flag (with ssid, password, hostname together) to flash the microSD Card for the Pi 3.

I found its default is using eth0. I have not much LAN cable in hands, so I tried to modify /etc/cluster-lab/cluster.conf manually to "wlan0". Doing this I got error message above.

I tried to follow the steps and changes those parameters. However I got 'No route to Host' when I connect the Pi 3 via SSH. I tried several times for different values.

Finally, I start it over, I flash the microsSD again, without --clusterlab true flag.

  1. Boot HypriotOS Cluster Lab on Pi 3 and SSH connect to it.
  2. I change value of INTERFACE in /etc/cluster-lab/cluster.conf to "wlan0" (I changed only this one for my "incremental test" purpose), and save it.
  3. I use VERBOSE=true cluster-lab start to see what happens.
  4. Oh yeah! almost all [PASS]. I can access at http://{IP of the node}:8500 to see the Consul web interface.
  5. To see if there are any [FAIL]s, I typed cluster-lab health, this time, really all [PASS]. Thanks so much :)

I suspected that --clusterlab true flag would go for some config assuming eth0 in use for the first boot. Also, it appeared that it also appends some docker related values in device-init.yaml (this point I am not sure, could be I wrongly added to it...oops)

oktak avatar Aug 02 '16 22:08 oktak