Bot cannot connect to Lavalink node on same public IP (possible hairpin NAT issue)
Posted by friend_xoo in discord-bots.
Hi, I have two separate servers under my account, both running on the same node/public IP (78.154.103.2): Discord bot server: b9428f94 Lavalink server: 96aa3b22 (Primary port: 78.154.103.2:9632) The Lavalink server is running and healthy — logs show: "Lavalink is ready to accept connections." The bot server is also running fine and logs in to Discord successfully, but it cannot establish a connection to the Lavalink node: "ERROR vocard Node DEFAULT is not able to connect! Reason: The connection to node 'DEFAULT' failed." I've triple checked the config on the bot side — host (78.154.103.2), port (9632), and password all match exactly what's shown in the Lavalink server's Network/Ports page. There's no typo. Since both servers share the same public IP, I suspect this may be a hairpin NAT issue — the bot container trying to reach its own node's public IP might not be routed correctly by the network/firewall. Could you please help confirm: Is hairpin NAT supported between containers on the same node? If not, is there an internal/private IP or hostname I can use instead of the public IP (78.154.103.2) to connect between these two servers on the same node? Thanks for your help!
Replies
tirito
cross connection is disabled by default from what i remember, open a ticket about this to whitelist the connection
friend_xoo
I booked my ticket several days ago and haven't heard back yet.