Add interface to currently running instance
I have 2 networks, net1
and net2
. I have an instance named test-fedora
that is on the net1
network. Is there a way to add the pre-existing test-fedora
instance to the net2
network?
I didn't see anything in the dashboard interface, so I tried
PORT_ID=$(quantum port-create net2 | grep ' id ' | awk '{print $4}')
nova interface-attach --port-id $PORT_ID test-fedora
After doing this, the "Network Topology" page on the dashboard showed test-fedora
as being connected to both networks, but when I log into test-fedora
and issue ip link
, I only see the the interface on net1
. I tried rebooting the instance, but the interface still doesn't show up.
Did you configure the network for the second interface by adding one file /etc/sysconfig/network-scripts/ifcfg-eth1? I add this file for eth1, then reboot the VM. The interface can show up.