Page 1 of 1

A big problem with DHCP and static IP ...

Posted: Fri Feb 19, 2016 11:01 am
by gommaloano
I think I read online that they are not alone in having this problem

In practice, the raspberry with raspbian takes the ip from dhcp and ignores the file /etc/network/interfaces

Here is how I write in the file:
iface eth0 inet static
address 192.168.17.150
netmask 255.255.255.0
network 192.168.17.0
broadcast 192.168.17.255
gateway 192.168.17.1

Has anyone solved?

Re: A big problem with DHCP and static IP ...

Posted: Fri Feb 19, 2016 11:03 am
by RaTTuS
by reading
see

Code: Select all

 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:
...

Re: A big problem with DHCP and static IP ...

Posted: Fri Feb 19, 2016 11:07 am
by karrika
In Jessie the file to edit is /etc/dhcpcd.conf

interface eth0
static ip_address=192.168.1.2/24
static routers=192.168.1.1
static domain_name_servers=8.8.8.8