add ips to linux server
Posted on 09. Jan, 2010 by Yao Yuan in Tips & Skills
cd /etc/sysconfig/network-scripts
ls -l
可以看到有
ifcfg-eth0 等
新建文件ifcfg-ethX,X为现有的序号的递增,如:
vi ifcfg-eth1
填入:
# Broadcom Corporation NetXtreme BCM5721 Gigabit Ethernet PCI Express
DEVICE=eth1
BOOTPROTO=none
HWADDR=00:e0:81:41:28:ee
ONBOOT=yes
NETMASK=255.255.255.248
IPADDR=204.13.64.188
GATEWAY=205.209.161.17
TYPE=Ethernet
IPADDR值为你要添的IP
有多少IP就新增多少ifcfg-ethX文件
然后运行:
/etc/init.d/network reload
使添加的IP生效
Related Posts
Related posts brought to you by Yet Another Related Posts Plugin.
br>





Leave a reply