首先,看到标题可能比较晕,为什么又多了个网络节点,一般情况下,这里介绍的都是物理环境,一个控制节点,一个计算节点,但是我们虚拟机之间也存在内部网络,所以我们也需要有一个逻辑的网络节点,我们又经常将网络节点和计算节点放在一起,所以标题就成为了网络(计算)节点。
如果网络节点和计算节点放在一块,我们就需要在虚拟机添加一个新的网卡。
添加完毕之后,我们需要为新网卡赋予相关的网络信息
sm@computer:~$ sudo more /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.3.181
netmask 255.255.255.0
gateway 192.168.3.1
auto eth1
iface eth1 inet manual
up ip link set dev $IFACE up
down ip link set dev $IFACE down
我们看到,原来我们设置的网卡eth0的IP信息,现在我们为新网卡eth1设置相关信息。
一、预备工作【network】