一,配置第二块网卡
1) 在虚拟机中配置eth1。
2)首先给eth0:192.168.142.130的虚拟机,添加第二块网卡设备。选中虚拟机,右键设置,添加网络适配器。

3)配置。将eth1配置成为内网ip:10.107.1.130。
# vi /etc/sysconfig/network-scripts/ifcfg-eth1
device=eth1 #hwaddr=00:0c:29:f5:6e:85 type=ethernet onboot=yes nm_controlled=yes #bootproto=dhcp bootproto=static ipaddr=10.107.1.130 netmask=255.255.255.0 ipv6init=no dns1=192.168.142.2
4)重启网卡。
# service network restart
5)检查配置
# ifconfig

二,配置多个内网ip
1)用一中同样的方式,eth0:192.168.142.133的虚拟机;配置第二块网卡eth1:10.107.1.133。则10.107.1.130和10.107.1.133配置为同一个网段的内网ip。
2)在10.107.1.133可以ping通10.107.1.130。
