I'm trying to make my raspberry pi move between multiple access points, some using DHCP other are static. I read that using id_str
in your wpa_supplicant networks and having the corresponding configuration in /etc/network/interfaces
can automatically configure the interface but doesn't look like it's the case in my system.
/etc/network/interfaces :
auto lo
iface lo inet loopback
auto eth0
allow-hotplug eth0
iface eth0 inet dhcp
iface eth0 inet6 auto
auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
#iface default inet dhcp
iface test inet static
address 192.168.0.2
gateway 192.168.0.1
netmask 255.255.255.0
/etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=DIR=/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="Skynet Defence Network"
key_mgmt=WPA-PSK
proto=WPA2
psk="illbeback"
priority=10
id_str="test"
}
with this configuration wpa_supplicant connects to the network but the network settings are not set. am i doing something wrong here ?