Bug Report: HAProxy is not supported.
General information
The player in Sonar connected via HAProxy is from 127.0.0.1.
Steps to reproduce
- Set
<server>config/paper-global.yml->proxies.proxy-protocoltotrue. - In
frpc.tomlsettransport.proxyProtocolVersion="v2"). - Restart server and frpc.
- Worked fine, the server thought the player was joining from their real IP address.
- Sonar print every player's IP is
127.0.0.1.
Sonar dump
sonar dump [00:47:14 INFO]: [Sonar] 生成信息: {"memory":{"total":"8 GiB","max":"32 GiB","free":"4 GiB","used":"4 GiB"},"runtime":{"virtualCores":24,"jvmArguments":["-XX:ThreadPriorityPolicy\u003d1","-XX:+UnlockExperimentalVMOptions","-XX:+EnableJVMCIProduct","-XX:-UnlockExperimentalVMOptions","-Xms8G","-Xmx32G"],"vmName":"Java HotSpot(TM) 64-Bit Server VM","vmVendor":"Oracle Corporation","vmVersion":"24.0.2+11-jvmci-b01"},"os":{"name":"Windows Server 2025","arch":"amd64","version":"10.0"},"sonar":{"version":"2.1.35 (3ca1852e)","platform":"BUKKIT","gitBranch":"main","gitCommit":"3ca1852e"}}
Additional information
The full server log is here:
https://mclo.gs/6tDsnye
This is important... The server now appears to be under attack. Because the IP address is not correctly identified, I can only temporarily disable the blacklist first and always use CAPTCHA.
Here is the log from frpc:
https://mclo.gs/AQ7PU0o
I am currently on vacation, so I am unable to look into this issue for now.
@FallenCrystal If you've got time and want to help with this, please help me investigate this until I'm back. Any other help would also be appreciated.
The simplest solution for now would just be to use a proxy in front of your Paper server (Velocity, for example).
HAProxy is supported in Sonar, but I think the way Paper manages it is different from Velocity and BungeeCord...
HAProxy is supported in Sonar, but I think the way Paper manages it is different from Velocity and BungeeCord...
Thanks for the quick reply! Does this mean that if I use Velocity, it will work fine?
HAProxy is supported in Sonar, but I think the way Paper manages it is different from Velocity and BungeeCord...
Thanks for the quick reply! Does this mean that if I use Velocity, it will work fine?
After testing, I added a Velocity and it works fine. Thanks for your help.
After testing, I added a Velocity and it works fine. Thanks for your help.
Great to hear. We'll still continue to look into fixing HAProxy support on Bukkit platforms.
I have HaProxy enabled on Velocity, but for some reason Transfer with HaProxy does not work on Sonar. However, when I use this feature on the server for the same domain with HaProxy, everything works fine. The problem is specifically with Sonar.
It returns an error: cannot assign requested address: connect
The transfer to Velocity is included. The servers are operated by Cloudnet.
I have HaProxy enabled on Velocity, but for some reason Transfer with HaProxy does not work on Sonar. However, when I use this feature on the server for the same domain with HaProxy, everything works fine. The problem is specifically with Sonar.
It returns an error: cannot assign requested address: connect
The transfer to Velocity is included. The servers are operated by Cloudnet.
Which IP/domain are you providing in the transfer mode? If your players join through mc.example.com:25565, make sure to set the IP/port to exactly what they're joining with. If you have any more questions, please join the Discord server and provide more information about your issue there. https://jonesdev.xyz/discord