1

I have a problem with my installation of proxmox... until yesterday everything was working correctly and today a website that I had hosted there has stopped working, the problem is the following:

I have the proxmox with 1 public ip... and I configured the iptables to redirect the traffic except port 22 and 8006 of the proxmox to the ip 192.168.10.100 (Container with CPanel) now well... until yesterday it worked fine (All the month) today the container is active and everything but I can't access it from the outside

source /etc/network/interfaces.d/*

car it
iface lo inet loopback

iface lo inet6 loopback

iface enp4s0 inet manual

car vmbr0
iface vmbr0 inet static
         address 176.9.6.5/27
         gateway 176.9.6.9
         bridge-ports enp4s0
         bridge stp off
         bridge-fd 0
         postup sysctl -w net.ipv4.ip_forward=1
         post-up iptables -t nat -A PREROUTING -i enp4s0 -p tcp -m multiport ! --dport 8006 -j DNAT --to 192.168.10.100
         post-up iptables -t nat -A PREROUTING -i enp4s0 -p udp -j DNAT --to 192.168.10.100
#route 176.9.6.8/27 via 176.9.6.9

iface vmbr0 inet6 static
         address 2a01:4f8:160:2458::2/64
         gateway fe80::1

car vmbr1
iface vmbr1 inet static
         address 192.168.10.1/24
         bridge-ports none
         bridge stp off
         bridge-fd 0
         post-up iptables -t nat -A POSTROUTING -s '192.168.10.100/24' -o vmbr0 -j MASQUERADE
         post-down iptables -t nat -D POSTROUTING -s '192.168.10.100/24' -o vmbr0 -j MASQUERADE

any can help me please

KatiaSisHost
  • 121
  • 2

1 Answers1

1

Solved, the problem is that the iptables were not saved and I always tried after restarting the server, so the iptables were deleted.

KatiaSisHost
  • 121
  • 2
  • for proxmox there is a good chance for "iptables-persistent" to install it to keep the rules – djdomi May 28 '23 at 14:36