This really shouldn’t be happening. If servers are just randomly crashing because of a single client crashing there is a serious problem going on somewhere.
It might not even be something you can fix, it may be a roblox issue. And, to be honest, it sounds like it might be.
But just to be sure, make sure the code you use to save the crashed player’s creation is wrapped in a pcall block to catch any errors because of the crash.
It is already wrapped in a pcall.
Also i tried replicating it in a local test server in studio and everything was fine there. The server only freezes ingame.
There isn’t very much that can cause a roblox server to crash. They’re generally built very robustly (and rightly so). So, you must be doing something which the server simply can’t handle.
Have you double checked all your code to make sure there isn’t anything there which could cause a crash.
Also, this idea is possible:
I know that simply clearing terrain can cause serious lag. Deleting a large number of parts could have the same effect.
I already tried that, but the server still crashed. I have double checked my code and everything seems to be fine, But i have a feeling it might be because of some weird networkowner bug since i have seen a lot of issues in my game such as replicating issues and the server its ping changing because of the client it’s physics.
Freezing and crashing are two different things. What exactly do you see as another player in game? Are all players disconnected almost immediately, or do you see a period of 10+ seconds where things don’t appear to be updating (apart from your own character and any other client-side things), and then you get disconnected?
Once the server freezes, You wont be able to build because the server froze and it shows all of the players are still connected for about 2+ minutes until you get kicked out with error code 277.
Nothing was working on the server, It litterally froze completely.
The error 277 usually means that the client lost a stable connection to the game server. Are all the players getting removed at the same time with that error, or do they drop out periodically? If they all get kicked at once, it’s not a network issue. If they drop out in turn, then it’s probably a network issue.
That doesn’t sound like a crash to me. If the server crashed, it would usually close. As @EmilyBendsSpace said:
It may have got stuck doing a heavy task that never got completed and your computer ended up showing it as not responding because of that. I noticed that in the video you put in the post, you accepted the option to kill the server process. Maybe wait and see if it responds. If it never responds, then the task it seems to be processing is too great causing a total freeze up.
One last thing, try having a look in the performance stats in the client during the freeze. Specifically, have a look at the data receive and data sent. If data receive is really low or on zero, that confirms that the server isn’t responding and has stopped sending data, explaining the error code. Also, right before the crash, have a look at the memory of the server. Is it abnormally high? Is there some other performance stat that is out of place?
Take a look at this and see if you notice anything.
(sorry for the long message, by the way, I had a lot to say)
The server freezes. All of the stats which require the server are frozen aswell.
All i see is that the ping jumps to 300 because of the parts, But it easily jumps back to 50 in studio.
It looks like theres no stress at all.
The memory is about 700 mb.
Okay, it’s definitely not the network. I’m running out of ideas fast.
Is there something being done on the client that could not be replicated to the server properly? Similar to the bug which caused anchoring the HRP on the client would crash the server.