MrTV
asked on
how can i set fix ipaddress indebian
How can i set fix ip address in debian what file and where is it
steps
1) go to /etc/sysconfig/network-scr
2) cp ifcfg-eth0 ifcfg-etho.bak ( just backup the file in case if you mess up anything)
3) vi ifcfg-eth0
change the BOOTPROTO= static
--------------------------
DEVICE=eth0
BOOTPROTO=static
HWADDR=04:60:9F:79:2E:6C
IPADDR=xxx.xxx.xx.xx An example of how the file looks like
NETMASK=255.255.252.0
ONBOOT=yes
TYPE=Ethernet
--------------------------
Also give the ipaddr in case if you want to change it
sorry fpintos ...we gave the same solution at a gap of 4 mins...coincidence hehehe
No need to be sorry... I got in before you.... :-)
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You will also want to run this command:
/etc/init.d/networking restart
This will cause the changes to take effect
/etc/init.d/networking restart
This will cause the changes to take effect
/etc/sysconfig/network-scr
You will have one config file per ethernet interface
The content looks like the following for FIX ip address:
DEVICE=eth0
BOOTPROTO=static
BROADCAST=192.168.6.255
IPADDR=192.168.6.204
NETMASK=255.255.255.0
NETWORK=192.168.6.0
ONBOOT=yes
Hope this help.