GRE tunneling using Open vSwitch
Solution 1:
I got it working. This answer helped me. I had two problems with my config.
First, I should have added an IP address for the nested guests. With tap0
up and connected to the nested guest, I configured a static IP for the nested guest.
Second, I noticed that I have a duplicate MAC address. That was because I had cloned the Guest1
after the installation of the Nested Guest 11
, so Nested Guest11
and Nested Guest21
had the same MAC address. I changed the MAC address of Nested Guest21
and tried again.
It didn't worked at first. I was forced to restart Guest1
because of a crash. After that I tried again. This time the nested VMs were able to ping each other.
My configuration:
Guest 1
ovs-vsctl show
Bridge br0
Port gre0
Interface gre0
type: gre
options: {remote_ip="192.168.239.129"}
Port tap0
Interface tap0
Port br0
Interface br0
type: internal
ovs_version: "2.15.0"
ip -br a
lo UNKNOWN 127.0.0.1/8 ::1/128
ens33 UP 192.168.41.140/24 fe80::4f54:fbff:6d87:b5a7/64
ens34 UP 192.168.239.128/24 fe80::761f:aa88:a28a:aeba/64
virbr2 DOWN 192.168.10.1/24
virbr2-nic DOWN
virbr1 DOWN 192.168.100.1/24
virbr1-nic DOWN
virbr0 DOWN 192.168.122.1/24
virbr0-nic DOWN
vboxnet0 DOWN
ovs-system DOWN
br0 DOWN
gre0@NONE DOWN
gretap0@NONE DOWN
erspan0@NONE DOWN
gre_sys@NONE UNKNOWN fe80::989f:9eff:fe5d:d7ce/64
tap0 UP fe80::9401:52ff:fe46:86e6/64
Nested Guest11
Guest2
ovs-vsctl show
Bridge br0
Port tap0
Interface tap0
Port gre0
Interface gre0
type: gre
options: {remote_ip="192.168.239.128"}
Port br0
Interface br0
type: internal
ovs_version: "2.15.0"
Nested Guest21
Forgot to add that in this case too, there is no connection between guest and nested guest, which I think is expected.