If the Crashes page says “The server crashed”, restart the server. If it crashes again at the same moment, the last mod or plugin you added is the first thing to take off.
Confirm it was a crash
- Open the Crashes tab.
- Under Starts, choose the start that ended badly. It can be marked Crashed (“The game stopped without being asked to.”), Ended early (“The log ends without saying how the server stopped.”) or Stuck, restarted (“The game stopped answering, so the panel restarted it.”).
- Read the header: Exit code and Out of memory. Then look under What the panel can tell for the finding “The server crashed”. It can sit on any of the three.
The panel makes the finding when the log holds a line such as Unhandled exception., Segmentation fault or Fatal error.. A chat message never makes a finding, even if a player types those words.
Two other findings can sit on a Crashed start. “The game ended on its own with code (N)”: 137 means the server was killed, 139 means it crashed inside the game. “The server used all its memory and was stopped” shows with Out of memory Yes: the machine ended the server and it could not write why. For that one, see the server ran out of memory.
Restart once
- Choose Start at the top of the server page.
- Wait for
Type 'help' for a list of commands. - Play as normal. If it stays up, the cause was a one off.
The game saves now and then, and when the last player leaves. After a crash, the world is as it was at the last save. Recent building may be missing.
If it crashes again at the same moment
The same crash at the same point has a cause that is still there. Remove what changed last.
- Think back to the last thing you added: a mod on tModLoader, or a plugin on TShock.
- On tModLoader, open the Mods page, take the newest mod off the list, and choose Apply, or Apply and restart while the server runs. That restart disconnects everyone, so use Message everyone first.
- On TShock, plugins live in
bin/tshock/ServerPlugins. Stop the server, open Files, take out the newest plugin file, and start the server. - Check Crashes after the next start.
Vanilla has no mods or plugins. A repeating crash there is a world or memory problem. Read the other findings on the same report.
If it does not work
- Still the same crash with nothing changed. Put a world backup back. See the world could not be loaded for how. The game keeps earlier saves beside the world.
- The finding is about memory. See the server ran out of memory.
- The server will not start at all. See the server will not start.
More about the game: Terraria servers.