How to View Logs on a Terraria Server
in Terraria
By Dalton Whalen
Overview
Playing on a dedicated Terraria server can be lots of fun as you build and explore with others. Issues may arise eventually, however, requiring you to check the server console for more information. Whether this is because of a problematic player or a crash, sometimes the text may disappear before you can read it. This is where server logs come in, which save the console text in a file to view later on. While vanilla Terraria does not save this by default, changing your server to TShock will allow you to save and view logs at any time. Switching your Terraria version is easy with our Apex Hosting panel, so we have created this tutorial to help you get started.
Finding Logs
By default, the vanilla version of Terraria does not allow you to properly view log files. This can be inconvenient if you are trying to find information from the server or are trying to diagnose an issue. Thankfully, a quick adjustment will start generating the necessary logs.
Switching to TShock
TShock is a variation of Terraria that improves a variety of hosting features, including plugins and log files. For a full tutorial on installing TShock, visit our guide here.
- Navigate to the Apex server panel, then stop the server.
- Scroll down to the
Game File
section of the panel, then open the dropdown. - Select
Terraria (TShock)
, then follow the prompt to change the version. - Choose whether or not to create a new world, then restart the server when prompted.
Once the server has started up, the log files will be accessible for viewing!
ServerLog.txt File
The ServerLog.txt file is easy to access, however it primarily stores the startup information of TShock. This includes IP information, plugin versions, and more. You may wish to check this file if there is an issue with the server startup.
- From the Apex panel, enter the
FTP File Access
from the left-hand menu. - Use your panel password to log in and view available files.
- Scroll down and find the
ServerLog.txt
file near the bottom. - Press
Edit
to the far-right to open the file.
Full Server Logs
For more detailed information about how the server has been running, you will want to check the full server logs. This will log any information provided in the server console, allowing you to view players, console commands, and more.
- From the Apex panel page, enter the
FTP File Access
and log in. - Locate and enter the
tshock
folder, followed by thelogs
folder. - Using the timestamps in the file names, find the log you wish to view.
- Press the
Edit
button to the far-right to open the log file.
Common Issues
None of the log folders or files are present:
The most common cause of this is if TShock has not run on your server. This is often evident by the ServerLog.txt and the tshock folder being entirely missing from the FTP File Access. To fix this, ensure the Game File has been changed to Terraria (TShock) and that the server has been fully restarted. Afterwards, the files and folders should appear normally.
I can’t find a specific log:
By default, each of the logs will have their designated time stamp in the name, in the yyyy-mm-dd format. Using this, you should be capable of tracking down the exact log file that you need. Additionally, there may be multiple logs for a given day, as a new log is generated upon each restart. Using this information, find the necessary log based upon when the last restart was.
Helpful Links
How to Install TShock for Terraria
How to join a Terraria Server