GeyserMC / Geyser

A bridge/proxy allowing you to connect to Minecraft: Java Edition servers with Minecraft: Bedrock Edition.
https://geysermc.org
MIT License
4.63k stars 663 forks source link

May reached packet limit when lots of bedrock player connect through same reverse proxy at the same time #4835

Closed BUGTeas closed 2 weeks ago

BUGTeas commented 2 weeks ago

Describe the bug

I use a UDP reverse proxy to forward geyser connection to another port. but when lots of players online on the same time, may reached the packet limit cause all of the player timed out.

To Reproduce

  1. Configure server and a UDP reverse proxy (Nginx stream or frpc) on same server, this proxy forward all packets to the geyser configured port (like 19132) of 127.0.0.1 address
  2. let all bedrock player join through this proxy
  3. May appeared on the console: [org.cloudburstmc.netty.handler.codec.raknet.server.RakServerRateLimiter] [/127.0.0.1] Blocked because packet limit was reached
  4. After about 30 seconds, all the bedrock player join through this proxy will kicked by connection timed out.
  5. After that, appeared on the console: [org.cloudburstmc.netty.handler.codec.raknet.server.RakServerRateLimiter] Unblocked address /127.0.0.1
  6. I tried to use Proxy Protocol V2 to avoid this, but nothing worked.

Expected behaviour

Provide a option to disable packet limit in whitelisted or all addresses

Screenshots / Videos

No response

Server Version and Plugins

Leaves version git-Leaves-"10acfe9" (MC: 1.20.2) (Implementing API version 1.20.2-R0.1-SNAPSHOT) (Git: 10acfe9) CompatNoCheatPlus, ConsoleSpamFix, CoreProtect, CrossplatForms, FCUB(made by myself), floodgate, Geyser-Spigot, GrimAC, InvSeePlusPlus, NoCheatPlus, NoPlugins, PCUB(made by myself), PlaceholderAPI, ProtectFarmLand, ProtocolLib, SimpleStack, SkinsRestorer, SpigotPing, Themis, UseBlessingSkin, ViaVersion

Geyser Dump

https://dump.geysermc.org/0DLPDXkbcmGdv9PW0jscuqy4IyhK5zcl

Geyser Version

2.4.0-b589 (git-master-ff1e1dd)

Minecraft: Bedrock Edition Device/Version

1.20.80 - 1.21.1

Additional Context

This problem is appeared for a long time, and not only in the current geyser version. I encountered same ploblem on Spigot 1.20.1. I thinked this problem haven't not any ties on other plugins, except Viaversion.

onebeastchris commented 2 weeks ago

This is caused by improper configuration. There are two options:

BUGTeas commented 2 weeks ago

Thanks.