1

I'm using lightweight VM lkvm which creates tun interfaces on the host. Now I want to connect two instances of lkvm over bridge interface, similar to what other VMs do:

               VM1                          VM2
          +----------+                 +-----------+
          |          |                 |           |
tap0 -----+eth0  eth1+--tap1-----tap2--+eth0   eth1+--tap3-
          |          |                 |           |
          +----------+                 +-----------+
  • both VMs have routing enabled, and rp_filter disabled (not sure it's needed, but I read it somewhere, so disabled just in case)
  • both VMs have relevant routes installed
  • both VMs have correct IP addresses set on the interfaces
  • bridge interface was created on host with ip tool, set up and running, tap1 and tap2 are added in the bridge (no IP addresses were added on tap1 and tap2 or bridge device -- not sure if it matters)
  • enabled IP forwarding on the host
  • subnets as follows VM1 eth0 20.20.20.2/24 eth1 30.30.30.2/24 VM2 eth0 30.30.30.3/24 eth1 40.40.40.2/24

However it doesn't work for some reasons. I can't ping from VM1 eth1->tap1->br->tap2->eth0 (although I see packets on tap1 and bridge device, but not on tap2) or the other way around from VM2.

What am I doing wrong?

  • Can you double-check br_netfilter is not enabled on the host? either the br_netfilter module is not loaded, or if it is, /proc/sys/net/bridge/bridge-nf-call-iptables set to 0 (same for bridge-nf-call-arptables): your bridge is perhaps filtering using host's iptables... if it was, does the behaviour change once disabled? – A.B Feb 13 at 22:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.