Server Crashes that yield any functions responsible for saving player's data

Hello everyone, I’m one of the Co-Owners of my game: “Land of Lizards 2” that has been undergoing it’s beta stage for the past ~4 months.

The only issue our game is facing as of the moment that is keeping it in beta stage, are the random server crashes that players experience. Whenever these servers do crash, it seems that :BindToClose, as well as the .PlayerRemoving function ceases to work.

I’ve seen some examples of this, and the only solutions are that “ROBLOX updated the clients”. These problems are similar to mine that have happened years ago, yet the updates don’t seem to be helping our games in this situation. I’ve also completely re-organized my code to use coroutines for looping, resource-hogging functions like .Touched and such, etc.

Players tend to have this happen randomly with no lag or freezing prior to it.
If anyone may know some leading factors that can lead to it, I’d happily appreciate any suggestions or ideas. Thank you!

Check your server’s memory usage, especially LuaHeap (indicative of a memory leak). There’s a hard limit and the server will crash right after surpassing it with no warning. IIRC it’s around 4-6 GB.

Mine is usually maintained at 1.8-2.2. The most I’ve ever seen was 2.6GB