kvm-scripts icon indicating copy to clipboard operation
kvm-scripts copied to clipboard

Guest to guest communication through host (forwarded port) not working

Open se1by opened this issue 3 years ago • 1 comments

Hey, first of all: thanks for your work!

I got this forward: addForward testvm1 enp0s31f6 <public_ip> 30001 virbr0 192.168.122.38 30001 tcp

This works flawlessly from any other host. If I try to connect to this port from the host, I get a connection refused. If I try to connect from another guest, I get a timeout. My guess is that it's not going through enp0s31f6, but I can't seem to figure out how to solve this. Any help would be appreciated!

In case it matters, I tested this by running netcat -l -p 30001 on testvm1 and date|netcat <public_ip> 30001 from everything else.

se1by avatar Jan 22 '22 22:01 se1by

I switched to writing my own hook script (https://github.com/se1by/libvirt-hook-nftables in case you're interested). I don't limit the rule to a specific device, so guest to guest communication works for me.

se1by avatar Jan 30 '22 13:01 se1by

Thanks. I'll link your script on the README.

doccaz avatar Dec 14 '22 03:12 doccaz