update redhat dynamic IP to static IP


update redhat dynamic IP to static IP
 
step1: add gateway 
     vi /etc/sysconfig/network 
     add below "GATEWAY" line 
NETWORKING=yes 
NETWORKING_IPV6=no 
HOSTNAME=localhost.localdomain 
GATEWAY=192.168.1.1 
  www.2cto.com  
step2: add your new IP address 
      update dhcp to static, 
      add your ipaddr line 
      add your netmast line 
 
DEVICE=eth0 
#BOOTPROTO=dhcp 
BOOTPROTO=static 
HWADDR=00:CC:23:3A:C3:EF 
IPADDR=192.168.1.200 
NETMAST=255.255.255.0 
ONBOOT=yes 
 
step3: update name server 
vi /etc/resolv.conf 
nameserver x.y.z.p 
(normal, below step won't need, cause it will automaticlly get your name server) 
 
step4:verify the static ip config effect: 
ifconfig eth0 
 

相关内容

    暂无相关文章