Is it possible to do port forwarding when using sdn?

rhx9

Member
Sep 15, 2022
2
1
8
Hi,
In the past i have setup a nat network manually using the /etc/network/interfaces file, using something like:


Code:
iface vmbr1 inet static
        address 192.168.1.1/24
        bridge-ports none
        bridge-stp off
        bridge-fd 0
        post-up   echo 1 > /proc/sys/net/ipv4/ip_forward
        # post-up iptables -t nat -A PREROUTING -i vmbr0 -p tcp --dport 3033 -j DNAT --to 192.168.1.2:22
        post-up   iptables -t nat -A POSTROUTING -s '192.168.1.0/24' -o vmbr0 -j MASQUERADE
        post-down iptables -t nat -D POSTROUTING -s '192.168.1.0/24' -o vmbr0 -j MASQUERADE

This sets up a network in addition to a port forwarding rule that i can enable/disable by commenting



Now that i have read about SDN i switched to SDN because it has a gui, but now i don't see a way to setup port forwarding.

Is there a way to set up port forwarding when using SDN?
 
  • Like
Reactions: pazter1101
I am also interested in this question. I have 5 pve nodes, each has a chr, EoIP tunnels are forwarded between the chrs, VLANs go in the tunnels - this is a large complex structure distributed across data centers in different countries. And I was very happy when SDN appeared in proxmox 8.. but I really need port forwarding from the external interfaces of the nodes to VM/LXC. I want to understand the architecture, how to set this up
 
currently you need to keep your "post-up" iptables PREROUTING rule , as port forwarding need to done manually.

Would be great if PREROUTING rules can be managed by PVE Firewall directly.
 
Last edited:
  • Like
Reactions: pazter1101

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!