Reply To: [SOLVED] Fixed IP – DHCP still working and I get two IP addresses

Max2Play Home Forums General Questions on Hardware and Max2Play Versions [SOLVED] Fixed IP – DHCP still working and I get two IP addresses Reply To: [SOLVED] Fixed IP – DHCP still working and I get two IP addresses

15. November 2017 at 19:26 #32495

Hi everyone,

I’ve tried to make a static IP both for Network and WiFi. When I made some changes to dhcpcd.conf file my result was as above : 4 IP address (two for Network,two for WiFi and all they were working!). I went through wpa_supplicant.conf files (they are two of them: one original in /etc/wpa_supplicant/ and second one, which is used by max2play, in /opt/max2play/ ) but nothing has got better. I’ve read some notes about raspbian jessie and found very simple solution.

Only what you need to do is go to /etc/network/interfaces and change lines to this (addresses are only for example):


# /etc/network/interfaces
auto lo
iface lo inet loopback

#auto eth0 # managed by ifplugd
#iface eth0 inet dhcp   <--- if you what to have static IP for Network hash this line and use dhcpcd.conf file to determine your IP
#hwaddress ether 1a:64:b6:bf:36:37

allow-hotplug wlan0
auto wlan0
iface wlan0 inet static #change dhcp to static
address 192.168.0.50  #static IP for RPi
gateway 192.168.0.1  #IP of your router
netmask 255.255.255.0  
wpa-ssid "NETWORK_SSID"
wpa-psk "PASSWORD"
#pre-up wpa_supplicant -B w -D wext -i wlan0 -c /opt/max2play/wpa_supplicant.co$ 
#post-down killall -q wpa_supplicant  #hash last two lines 

Now my RPi3 with M2P onboard is connecting with the same IP to WiFi everytime.