Scenirio: one KVM host(192.168.86.121) has configured KVM hypervisior which have some VMs(10.33.2.0/
Scenirio: one KVM host(192.168.86.121) has configured KVM hypervisior which have some VMs(10.33.2.0/24) running on top of it. we need other hosts (192.168.86.0/23) can access the KVM VMs. we need to Forward and PREROUTING.
1. enable the kernel forwarding
echo "1" > /proc/sys/net/ipv4/ip_forward
2. add the prerouting and forward.
iptables -t nat -I PREROUTING -d 192.168.86.121 -p tcp --dport 9022 -j DNAT --to-destination 10.33.2.50:22
iptables -I FORWARD -p tcp -d 10.33.2.50 --dport 22 -j ACCEPT
now we can access the 10.88.2.50:22 via 192.168.86.121:9000