How to set/change ipaddress in linux terminal?
In order to set or change the IP address assigned to a certain interface in your linux machine you can use GUI. Use System -> Administration ->Network. But it is not always possible to use GUI. Sometimes you need to use terminal commands (like if you are ssh'ing).
Login as root and use the following command:
#ifconfig eth0 11.11.1.178 netmask 255.255.248.0
where eth0 is the interface you want to configure
11.11.1.178 is the ipaddress being assigned to that interface
255.255.248.0 is the subnet mask
we can use system-config-network to configure DNS settings.
Login as root and use the following command:
#ifconfig eth0 11.11.1.178 netmask 255.255.248.0
where eth0 is the interface you want to configure
11.11.1.178 is the ipaddress being assigned to that interface
255.255.248.0 is the subnet mask
we can use system-config-network to configure DNS settings.
Comments
Post a Comment