AnsweredAssumed Answered

cannot get static IP

Question asked by sameerarvikar on Dec 1, 2017
Latest reply on Dec 3, 2017 by igorpadykov

Hi,
I am using Linux-krogoth over IMX6

 

I want the ethernet interface 'eth0' to have static ip address
for that i edit the file 
vi /etc/network/interfaces   

# The primary network interface auto eth0 iface eth0 inet static     address 0.0.0.0     netmask 255.255.255.0

i changed dhcp to static

 

I added 
ifconfig eth0 0.0.0.0
to the startup script of linux (rc.local)

 

still i am getting a dhcp address at eth0 interface
if there is no dhcp server available in network i get 
169.254.x.x ip address 
if dhcp server is available ,it gets an dhcp ip address

 

What might be the issue , do i need to change in any other file to keep eth0 interface ip as static ?? 
Please resolve

 


Regards
Sameer

Outcomes