I am trying to set a static ip address. The static ip is outside of my home dhcp range. But even after reboot, I can connect to the old dhcp ip address. Why does this happen? Take a look at the ip during login and in the ouput of ifconfig:
login as: pi
pi@192.168.0.205's password:
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Tue Jan 5 20:54:59 2016 from flucky-pc.lan
pi@druckerpi:~ $ ifconfig
eth0 Link encap:Ethernet Hardware Adresse b8:27:eb:7b:45:2b
inet Adresse:192.168.0.3 Bcast:192.168.0.255 Maske:255.255.255.0
inet6-Adresse: fe80::ba27:ebff:fe7b:452b/64 Gültigkeitsbereich:Verbindung
UP BROADCAST RUNNING MULTICAST MTU:1500 Metrik:1
RX packets:11358 errors:0 dropped:0 overruns:0 frame:0
TX packets:1300 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:1000
RX bytes:631413 (616.6 KiB) TX bytes:133922 (130.7 KiB)
lo Link encap:Lokale Schleife
inet Adresse:127.0.0.1 Maske:255.0.0.0
inet6-Adresse: ::1/128 Gültigkeitsbereich:Maschine
UP LOOPBACK RUNNING MTU:65536 Metrik:1
RX packets:41 errors:0 dropped:0 overruns:0 frame:0
TX packets:41 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:0
RX bytes:5671 (5.5 KiB) TX bytes:5671 (5.5 KiB)
pi@druckerpi:~ $ cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'
# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 192.168.0.3
netmask 255.255.255.0
gateway 192.168.0.1
dns-nameservers 192.168.0.1
#allow-hotplug wlan0
#iface wlan0 inet manual
# wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
#allow-hotplug wlan1
#iface wlan1 inet manual
# wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
pi@druckerpi:~ $
Is there something I am missing? I DONT want to be able to connect to 192.168.0.205 and instead use the static ip 192.168.0.3 (as set in /etc/network/interfaces
)