Score:0

How can I use iptables to forward port 15672 to the same port on a proxmox virtual machine?

ca flag

I have a virtual machine that contains a service that listens on port 15672. The server that the VM is on is set up to use iptables to forward requests to the virtual machines. Here are the relevant lines that forwards requests to the VM:

-A PREROUTING -d <server-ip> -i ens3 -p tcp -m tcp --dport 443 -j DNAT --to-destination <local-vm-ip>
-A PREROUTING -d <server-ip> -i ens3 -p tcp -m tcp --dport 80 -j DNAT --to-destination <local-vm-ip>
-A PREROUTING -d <server-ip> -i ens3 -p tcp -m tcp --dport 15672 -j DNAT --to-destination <local-vm-ip>
-A PREROUTING -d <server-ip> -i ens3 -p tcp -m tcp --dport 22 -j DNAT --to-destination <local-vm-ip>

-A POSTROUTING -s <local-vm-ip> -o ens3 -j SNAT --to-source <server-ip>

Web requests are currently working for ports 443 and 80, but I'm having trouble with 15672. When I run netstat -tlnp | grep 15672 on the VM, I get:

tcp 0 0 0.0.0.0:15672 0.0.0.0:* LISTEN 276/beam.smp

However, whenever I try to access http://<server-ip>:15672 I just get a timeout after a bit.

I wasn't the one who wrote these iptables rules, but I've been trying to parse them and figure out what they do. Is there anything that I'm missing to be able to get 15672 to respond?

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.