|
|
How to change ip address in Linux? - Linux
|
Views : 408
|
|
Tagged in : Linux
|
|
|
Report This Scrap as Inappropriate We request you to choose the appropriate categroy and subcategory that suits your
objectionable concern about the scrap, So that our team can review and find out whether it violates our Guidelines or the
scrap is not suitable for all viewers.
|
change IP address in Linux:
To change the IP address in linux, first list the current ip using "ifconfig" command.
# ifconfig eth0
It will list the IP address with subnet mask as,
eth0 Link encap:Ethernet HWaddr 00:22:64:4B:5F:A3
inet addr:192.168.1.5 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::222:64ff:fe4b:5fa3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
.......................................
.......................................
To set IP address from 192.168.1.5 to 192.168.1.10, enter command:
# ifconfig eth0 192.168.1.10 netmask 255.255.255.0 up
Finally check the IP address using,
# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:22:64:4B:5F:A3
inet addr:192.168.1.10 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::222:64ff:fe4b:5fa3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
.......................................
.......................................
Now the IP is changed.
Use this command to change IP address in linux. |
|
By Ramya, On - 2009-11-10 |
|
|
|