How to find a lag source + limit lag machines

I recently discovered that there is a massive lag source on my server. When someone entered its area, they immediately got 1 FPS and the whole server started lagging (TPS was going down). I realized my friends had a little fun and created a lag machine utilizing armor stands. Now, this helped me to locate the machine and destroy it, but it left me with a few questions... 1. In future situations like that, how would I locate a lag machine on my server? 2. How to protect my server from lags caused by armor stands? 3. Is there any way to prevent any lag machines that players may create? I would appreciate any info on that. Thanks.
45 Replies
Admincraft Meta
Admincraft Metaβ€’2y ago
Thanks for asking your question!
Make sure to provide as much helpful information as possible such as logs/what you tried and what your exact issue is
Make sure to mark solved when issue is solved!!!
/close !close !solved !answered
Requested by Biggie Cheese#8849
snowznz.bak
snowznz.bakβ€’2y ago
!spark
Carl-bot
Carl-botβ€’2y ago
Spark Profiler
Spark can be used to see why your server or client is lagging. https://spark.lucko.me/
From An unknown user
Admincraft Canned Responses
Deleted User
Deleted Userβ€’2y ago
you could try things like folia and multipaper
snowznz.bak
snowznz.bakβ€’2y ago
multipaper no, folia only if you have 16 cores, 32 threads
Deleted User
Deleted Userβ€’2y ago
they're very much not usable for production tho
ProGamingDk
ProGamingDkβ€’2y ago
Insights plugin can be nice
Discount Milk
Discount Milkβ€’2y ago
How would folia help here :FrogeBIGEYES:
Zacka The Dinosaura πŸ’…πŸ»
for question #2, i think you'll need a plugin to limit entities per chunk yes, that may be annoying for some players but its overall better for the server's performance
Zacka The Dinosaura πŸ’…πŸ»
something like this if not the plugin itself: https://www.spigotmc.org/resources/entitychunklimiter.67843/
SpigotMC - High Performance Minecraft
EntityChunkLimiter
Deleted User
Deleted Userβ€’2y ago
regionized multithreading, meaning it won't affect the other regions
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Thanks for your suggestions, however: 1. Spark lets me identify what's causing the lag, but I don't know if it's possible to check WHERE is it located in the world (without it it's hard to eliminate I guess). This basically gave me the same results as Paper's timings. 2. Insights plugin doesn't work in 1.20.1. 3. Is there any way to limit lag machines without installing plugins? I heard that many things don't require plugins (for example simple anti-lag plugins are a bullsh*t). EntityChunkLimiter sounds okay, but it was last updated in 2021 for 1.16... I am okay with installing plugins like that, as long as they really work and have no performance impact on my server overall. 4. I set do-collision-entity-lookups to false under the armor-stands section in my paper-world-defaults.yml file, and it seems it has helped to lower the lag a little.
ProGamingDk
ProGamingDkβ€’2y ago
https://modrinth.com/plugin/insights sent u the wrong link mb
Modrinth
Insights - Minecraft Plugin
Extremely fast region scans | Find large redstone machines | Limits per chunk / region | Custom region addon api
Discount Milk
Discount Milkβ€’2y ago
Well, if it's entities causing lag you do have the world tab you can use to see what is approximately where. For 3, how would you limit them without a plugin? Not sure how you'd modify game mechanics like that "without" a plugin.
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Yeah I know, I was just wondering if there are some options to limit that by things like (for example) engine configurations (like the one I mentioned in 4.) Alright, I will check this one Okay thanks, I found it. Now I see that there is a lot of armor stands in 1 region. My question is, how do I know which region is where? There are a lot of chunks mentioned, how do I teleport to them or something?
ProGamingDk
ProGamingDkβ€’2y ago
Discount Milk
Discount Milkβ€’2y ago
There is a regions section, it's numbered based on the region number. You can use a calculator to find the cords (Calc linked above)
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Okay, the calculator helped a lot! Now one more thing... Finding a chunk that contains a lag machine is a very big step towards disabling it, but... Any tips on how to find the exact coordinates or something? The thing here is that the lag machine I had to destroy was hidden in some other building so it wasn't normally visible. Using minecraft:kill @e[type=armor_stand,distance=..100] solved the problem, but what if there are lots of the other armor stands that aren't a part of a lag machine, but just regular other players' items? I would want to avoid deleting them. So, what is the recommended thing to do here? Can I somehow locate the machine and use distance..10 for example, or maybe there is another way to disable the machine?
Discount Milk
Discount Milkβ€’2y ago
You'd just have to do it the ol fashioned way Hunt em down
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Alright πŸ˜„ And back to my question from here ^ Is it possible to limit lag machines anyway just by a good configuration in Paper for example? Or installing some extra plugins is necessary? I don't have anything against installing plugins, it's just I already installed tons of them I don't want my server to lose the performance it currently has.
Discount Milk
Discount Milkβ€’2y ago
.
ProGamingDk
ProGamingDkβ€’2y ago
just having plugins doesnt reduce performance, it depends on what they do and how they do it
Discount Milk
Discount Milkβ€’2y ago
No, there's nothing inside paper itself that will prevent all/many/more than a few/etc lag machines.
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Okay, thank you for all your help and tips. Appreciate that. The Insights version from Modrinth works well. I'll try it and see what it can do. Do any of you recommend any other anti-lag machines, anti-exploit, or optimization plugins?
ProGamingDk
ProGamingDkβ€’2y ago
nope most of them are snake oil
Discount Milk
Discount Milkβ€’2y ago
Most optimization plugins are basically snake oil But anti-exist and anti-lag machine plugins do exist, and are "mostly" not snake oil I'm not sure of any I'd use off the top of my head though, @goosBanny might know of some
goosBanny
goosBannyβ€’2y ago
mhm!! clearlag can be useful on some servers. can help on very large (i'd say 100+ players) servers no matter what type, too. CAProtect-Lite, RedstoneLimiter, AntiRedstoneClock too entitydetection to easily find chunks with lots of entities
Discount Milk
Discount Milkβ€’2y ago
But don't expect clearlag to be like, end all be all. Most of its features are garbo
goosBanny
goosBannyβ€’2y ago
^ farmlimiter is great too. replaces CAProtect-Lite (capl isnt super optimized - farmlimiter can be configured to do it's job better) too bad it's paid πŸ˜”
goosBanny
goosBannyβ€’2y ago
Optimization | setup.md
This section of setup.md goes in-depth for server optimization
Anti-Lag | setup.md
A brief introduction to Anti-Lag and alternative performance management tools.
Deleted User
Deleted Userβ€’2y ago
and then there's Mob Farm Manager
goosBanny
goosBannyβ€’2y ago
oh yeah forgot to list that one
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Alright, thanks! I will look at them.
goosBanny
goosBannyβ€’2y ago
hm you never sent a spark report
Biggie Cheese
Biggie CheeseOPβ€’2y ago
If you remind yourselves of any other you can name or link them here.
Deleted User
Deleted Userβ€’2y ago
both of them are paid and exact same price :Sob_AE:
Biggie Cheese
Biggie CheeseOPβ€’2y ago
If any of them is worth the price, I might pay for it Also, has any of you heard of an ExploitFixer? It moved some time ago from SpigotMC to BuiltByBit and is now required to pay for it, but it seems like a good anti-exploit plugin... Is it worth it? Or maybe there are better free/paid alternatives?
goosBanny
goosBannyβ€’2y ago
suggestion: 1.20.1 panilla + lpx
Deleted User
Deleted Userβ€’2y ago
ExploitFixer and Panilla seems pretty good
goosBanny
goosBannyβ€’2y ago
all you need
Deleted User
Deleted Userβ€’2y ago
ah forgot lpx lpx and panilla are both paid but panilla can be compiled from its source
Biggie Cheese
Biggie CheeseOPβ€’2y ago
Ouch, LPX is much more expensive than ExploitFixer... Is it really worth the price?
QarthO
QarthOβ€’2y ago
What exploits are you looking to fix that paper doesn’t patch?
goosBanny
goosBannyβ€’2y ago
lpx does not do EF's job you should just keep the server updated EF isn't needed for latest servers
Deleted User
Deleted Userβ€’2y ago
anything exploitfixer claims to patch, just send them over to paper and they'll look into it iirc exploitfixer is opensource so it's that much easier for paper devs to fix

Did you find this page helpful?