vi /etc/sysconfig/network-scripts/ifcfg-eth0
按Insert 變edit mode
DEVICE=eth0 //網路卡名稱 BOOTPROTO=static //BOOTP協定 BROADCAST=192.168.202.255 //廣播 IP Address HWADDR=00:15:C5:E5:99:B1 //MAC Address IPADDR=192.168.202.100 //IP Address NETMASK=255.255.254.0 //Netmask (遮罩) NETWORK=192.168.202.0 //網段 ONBOOT=no //開機自動啟動
將最後一行變成
ONBOOT=yes //開機自動啟動
reboot
Comment feed