Repository navigation
10000 entries in serverNames, and possibly two million more in next weeks - will this be a problem?
#7322
|
My Ansible generates all possible combinations of domains used in XRay servers. This is increased as factorial of If I buy few new domains, it will generate a million of combinations will be produced, at least. Will this be a problem for XRay-Core with typical VPS setup, like 1 vCPU (5-10%)/2 GB of RAM/10 GB of storage? |
Replies: 1 comment 1 reply
|
the lookup itself is fine, the startup probing is what will hurt you
the real problem: when a REALITY RAW inbound starts, Xray runs so 10k is already heavy, 1M+ isn't realistic. |
the lookup itself is fine, the startup probing is what will hurt you
serverNamesbecomesmap[string]bool(reality/config.go) and REALITY checksconfig.ServerNames[hs.clientHello.serverName]per handshake (tls.go), so cost per connection doesn't grow with the list. exact match only, no wildcardsm-37.sub12.example-domain.com: about 48 MB for the strings plus 56 MB for the map, roughly double for 2M. Xray also holds the JSON and protobuf copies while loading, so plan for a few hundred MB at start on 2 GB, tight but not a crash by itselfthe real problem: when a REALITY RAW inbound starts, Xray runs
DetectPos…