There are a lot of these posts around here but none of them actually solved my problem.
I tried to set up my Pi B to use a static IP in my home network. Here are the things I did so far:
Changed /src/network/interfaces
to:
source-directory /etc/network/interfaces.d
auto lo
iface lo inet loopback
iface eth0 inet static
adress 192.168.1.171
netmask 25.255.255.0
network 192.168.1.0
broadcast 192.1668.1.255
gateway 192.168.1.1
However, regardless how many times I rebooted, ifconfig eth0
gives me the following:
Link encap:Ethernet HWaddr b8:27:eb:74:ab:fa
inet addr:192.168.1.213 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::d0c7:ac6d:5234:991e/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2074 errors:0 dropped:0 overruns:0 frame:0
TX packets:518 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:122376 (119.5 KiB) TX bytes:66904 (65.3 KiB)
Also, route -ne
gives me:
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth0
192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
I can only access the PI through 192.168.1.213.
Any suggestions how I can properly set up the static IP?