Server Setup (Windows, Local Host)
This guide focuses on setting up a local server on the same machine as the client running Windows OS. Return to Server Setup for other operating systems and configurations. Prism is used as the server software, running Java 17+.
Latest Revision: December 2023 version 2.4.0
Server Setup
Extract Server Files
![Extract Server Files Image](http://static.miraheze.org/gtnhwiki/thumb/f/fc/Extract_Server_Files.png/300px-Extract_Server_Files.png)
![Extraction Destination Image](http://static.miraheze.org/gtnhwiki/thumb/b/b3/Extraction_Destination.png/300px-Extraction_Destination.png)
Agree to EULA
![File Content](http://static.miraheze.org/gtnhwiki/thumb/d/de/EULA.txt_File_Content.png/300px-EULA.txt_File_Content.png)
By setting the text of the EULA.txt file to true you are agreeing to the following EULA.
You can edit the startserver-java9.bat
file if you want to change the memory usage from the default 6G (six gigabytes) - change both cases of "6G" to whatever memory amount you want. GT:NH will not run with less than 4G, and 6G should be a fine default until later.
Run the Server
startserver-java9.bat
![Firewall Prompt](http://static.miraheze.org/gtnhwiki/thumb/d/d9/Firewall_Warning.png/300px-Firewall_Warning.png)
Note: It may take quite some time for the server to startup.
If at this point you get an error like "Error: Could not find or load main class @java9args.txt
" and it immediately exits, your default Java version is probably Java 8. You can either change the default system Java, or edit startserver9.bat
and replace java
with the full path to the correct Java in quotes, something like "C:\Program Files\Java\jdk-17.0.6\bin\java.exe"
- if you can't find it, Prism or MultiMC may be able to find the list of installed Javas (edit a client instance, select Settings, click Auto-Detect).
![Console Window Image](http://static.miraheze.org/gtnhwiki/thumb/5/5c/Terminal_Window.png/300px-Terminal_Window.png)
stop
Danger!
stop
. Doing so can corrupt your world making it unplayable.
Next Steps
The server should now be functional, but there's still some things to set up. These next steps are universal regardless of platform or launcher, so head back to Server Setup. It's vital to choose and install a backup mod, because unlike SP the server pack does not ship with one included.