Jump to content

Dedicated Server Quick Setup Guide - Windows


Recommended Posts

12 hours ago, loopuleasa said:

that one

 

still a bit of an involved process

I used this method and it was relatively straight-forward in setting up multiple shards. I'm curious, though, what the benefits are to this method versus OP method of setting up a server through Klei. This method seems to require Steam installed and the OP method doesn't.

Edit: The pre-configured server option appears to have been phased out: 

 

Edited by JazzyGames
Link to comment
Share on other sites

On 1/5/2021 at 4:18 PM, JazzyGames said:

I used this method and it was relatively straight-forward in setting up multiple shards. I'm curious, though, what the benefits are to this method versus OP method of setting up a server through Klei. This method seems to require Steam installed and the OP method doesn't.

Edit: The pre-configured server option appears to have been phased out: 

 

My Don't Starve Together Dedicated server isn't opening two windows, which means I installed it wrong right? I tried 3 times to uninstall and reinstall it to click run pre-configured severs but I get /bin to open instead? Know how to reset that?  

Link to comment
Share on other sites

The video is super helpful, but starting DST Servers won't work because my whole hard drive files are on one drive for klei and because of that it wont run and null render thing pops up. Any way to remove my klei stuff out into my actual pc?? Okay nevermind I fixed it but nullrender still says its wrong rip me

Edited by Ali Bun
Link to comment
Share on other sites

On 1/4/2021 at 4:07 PM, JazzyGames said:

This guide is great but definitely needs to be updated. One thing I'd add as a recommendation to anyone updating via a .bat file is too remove the "validate" line. Otherwise Steam will always replace your dedicated_server_mods_setup.lua with the default blank file and you'll be unable to install mods.

Hello Jazzy. I used your video guide to set it up but I´m running into a problem. The bat file is able to open both servers (master and caves) but in both windows i get this:

[00:00:03]: !!!! Your Server Will Not Start !!!!
[00:00:03]: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
[00:00:03]: No auth token could be found.

I discovered that even when I dragged the files downloaded from the klei accounts page, when I go back and check the configuration is not the same that I typed. Any idea on how to solve it?

Link to comment
Share on other sites

Hello @cardplatypus, welcome to the forums.

If you followed this guide correctly, you should also be precise about the placement of the SteamCMD. In this guide, it tells you to follow the instructions on how to install SteamCMD. For windows, it would be by default placed in drive c.

Can you confirm that you've followed that step? If the SteamCMD was placed elsewhere on your PC, the StartDSTServers.bat file will not be able to find it.

Link to comment
Share on other sites

When i try to click and configure the server options from https://accounts.klei.com/account/game/servers?game=DontStarveTogether ,  no matter which option i click, it always sends me to this page. So i can't configure it and  i get "E_INVALID_TOKEN" error when i try to start the server.

 

Link to comment
Share on other sites

Just want to post here for the question I asked months ago that never got solved.  Just saw Jazzy's video on mods setup and it finally answered why my Dedicated_Server_Mods_Setup.lua kept getting wiped.  For anyone else who might be having the problem, don't forget to remove the "VALIDATE" parameter from the StartDSTServers.bat file or it will wipe it clean back to default every time (which was my battle).  Thank you so much for this small detail everyone else missed.  Head over to Jazzy's vid if you need more detailed explanation and visuals, and I hope no-one else will have to go through this same fustration.

Spoiler

 

 

Link to comment
Share on other sites

I have this crash problem :

 

[00:00:14]: [string "scripts/prefabs/chesspieces.lua"]:61: attempt to index field '?' (a nil value)
LUA ERROR stack traceback:
    scripts/prefabs/chesspieces.lua:61 in (upvalue) GetBuildName (Lua) <60-68>
    scripts/prefabs/chesspieces.lua:72 in (upvalue) SetMaterial (Lua) <70-81>
    scripts/prefabs/chesspieces.lua:193 in (method) OnLoad (Lua) <190-206>
    scripts/entityscript.lua:1601 in (method) SetPersistData (Lua) <1586-1603>
    scripts/mainfunctions.lua:356 in (global) SpawnSaveRecord (Lua) <321-363>
    scripts/gamelogic.lua:557 in (upvalue) PopulateWorld (Lua) <328-591>
    scripts/gamelogic.lua:807 in (upvalue) DoInitGame (Lua) <690-886>
    scripts/gamelogic.lua:920 in (local) cb (Lua) <914-921>
    scripts/shardindex.lua:199 in (upvalue) OnLoadSaveDataFile (Lua) <181-200>
    scripts/shardindex.lua:204 in () ? (Lua) <203-205>
    =[C]:-1 in (method) GetPersistentString (C) <-1--1>
    scripts/shardindex.lua:203 in (method) GetSaveDataFile (Lua) <202-206>

[00:00:14]: Check for write access: TRUE
[00:00:14]: Check for read access: TRUE
[00:00:14]: Available disk space for save files: 47358 MB
[00:00:14]: ModIndex: Load sequence finished successfully.
[00:00:14]: Reset() returning
[00:00:14]: Warning: Widget:SetFocusFromChild is happening on a widget outside of the screen/widget hierachy. This will cause focus moves to fail. Is   ScriptErrorWidget       not a screen?
[00:00:14]: stack traceback:
        scripts/widgets/widget.lua:605 in (method) SetFocusFromChild (Lua) <602-627>
        scripts/widgets/widget.lua:624 in (method) SetFocusFromChild (Lua) <602-627>
        scripts/widgets/widget.lua:624 in (method) SetFocusFromChild (Lua) <602-627>
        scripts/widgets/widget.lua:656 in (method) SetFocus (Lua) <629-665>
        scripts/widgets/menu.lua:83 in (method) SetFocus (Lua) <74-85>
        scripts/widgets/scripterrorwidget.lua:109 in (method) OnUpdate (Lua) <102-119>
        scripts/update.lua:95 in () ? (Lua) <33-134>

Link to comment
Share on other sites

Hello @Robemi1, welcome back to the forums. Did you already try the method given in those logs?

"Please visit: https://accounts.klei.com/account/game/servers?game=DontStarveTogether to generate configuration files."

It could be just an expired token. So go to that link and generate a new one. Refer to Step 5 and 6 of this guide.

Did you generate your configuration files through that? If not, it'll be easier on you to do so, since it gives you a prepacked server files with your own settings added in if you wish to configure the settings.

  • At the bottom click, Add Server.
  • Once New Server is added, click Configure Server.
  • Configure the basic details, then click Download Settings
  • This will generate a MyDediServer.zip file
  • You extract the contents of MyDediServer.zip file
  • Place the folder “MyDediServer” inside \\Documents\Klei\DoNotStarveTogether\.

On the other hand it could be location and foldername syntax errors. Is the MyDediServer in the correct folder? Refer to Step 8 of this guide for correct file locations. If you changed the MyDediServer folder name, you should also change the MyDediServer name inside the StartDSTServers.bat file (Refer to Step 7).

If that still fails for you, could you post the server_log.txt of the server that crashes that are worlds with caves as shown in the image? To get to the server_log.txt follow bellow:

  • When you go Host Game Screen and all your previously generated worlds are shown, click the FOLDER ICON that would be tagged "Open Cluster_#"
  • Documents\Klei\DoNotStarveTogether\Cluster_# will open and go to Master folder and get copy of server_log.txt, rename as master_server_log.txt
  • Go to Caves folder get copy of server_log.txt, rename as caves_server_log.txt
  • Attach both files in your next reply AFTER you've tried the methods mentioned above.
Link to comment
Share on other sites

Hi, @zillvr

Thanks, I can now run a dedicated server.

But I can't generate new worlds due to the "dedicated server failed to start" error message.

I already tried generating new tokens through the link and replacing them with old ones (that's why I don't get the error message on pre existing worlds with caves).

I'm having this trouble ever since the year of the beefalo update, I tried many different methods to solve this problem and I really hope you could help me.

Master_server_log.txt Caves_server_log.txt

Link to comment
Share on other sites

@Robemi1 Hmm, those log files show Cluster_9, you seem to have made a lot of server and kept them. The logs show that the E_INVALID_TOKEN as errors and thats usually when theres an issue with user input when making new tokens manually.

Can you go check the token you have under the Cluster_9 folder a go to https://accounts.klei.com/account/game/servers?game=DontStarveTogether and cross reference the list of tokens there (ctrl + F for the token you found in Cluster_9). If the token has expired, delete that token from the page and generate a new one.

One you generate a new token from the page, insert it into the token file for Cluster_9 and then start up the server.

Link to comment
Share on other sites

cluster 9 is not a dedicated server and from the moment I've started playing worlds generated within the game never appeared in that link.

I've tried this method and it worked for all my other worlds but, it seems really stupid that from now on I need to generate a new world wait for the error message and then go to klei account to generate a different token and replace it with the old one.

The problem isn't that I can't play. The problem is that for me to generate/resume a world within the game I need to start a dedicated server first or at the very least a token

Link to comment
Share on other sites

@Robemi1 That is really odd though, if I would assume Cluster_9 server is a server made through ingame's Host Game screen, then issues like INVALID TOKEN should not happen.

Do you perhaps no longer have enough space in your Operating System's drive that the game can't make new files? By default, Windows's Documents folder (which DST uses for saves) is the same folder your Windows Operating system is installed in. If there isn't enough space, the server won't work.

Another line of though is that the game files might be corrupted and fails to get valid tokens when you make new worlds through Host Game screen?

You are not using mods that modifies the host game screen in any way, right? Cause that is another possibility of the game failing to generate valid tokens from the get go.

Link to comment
Share on other sites

I still have plenty of space so I really doubt it.

I tried verifying the integrity of the flies through steam/ reinstall the game and even steam (yes, I was that desperate)/ going with a thumb drive to another pc to see if it'll work (the cluster opened without a problem), copying all game files from that pc to my pc to check if the download itself is faulty.

I disabled  and removed all mods from my game (even deleted it from the steam workshop folder to make sure there aren't any traces), reinstalled the game again and still nothing.

To sum up, the game works, the cluster works if I change the given token with a dedicated server token or if I try it on another pc, the mods have nothing to do with it, and the firewall doesn't block the game so I'm really clueless by now

Link to comment
Share on other sites

On 2/5/2021 at 1:01 PM, Raiden_Sola said:

Just want to post here for the question I asked months ago that never got solved.  Just saw Jazzy's video on mods setup and it finally answered why my Dedicated_Server_Mods_Setup.lua kept getting wiped.  For anyone else who might be having the problem, don't forget to remove the "VALIDATE" parameter from the StartDSTServers.bat file or it will wipe it clean back to default every time (which was my battle).  Thank you so much for this small detail everyone else missed.  Head over to Jazzy's vid if you need more detailed explanation and visuals, and I hope no-one else will have to go through this same fustration.

  Reveal hidden contents

 

 

This was driving me bonkers for the longest time, so I'm happy to share the info. Why a blank mod configuration file would be deemed an essential game file is beyond me. Would be nice if Klei eventually just removed dedicated_server_mods_setup.lua from the Validate files.

Link to comment
Share on other sites

@Robemi1 You already seem to have tried all workaround I can possibly think of and my only line of thought is that it could be an issue with the client save settings. A possible fix would be as follows:

  • Go to Klei//DoNotStarveTogether/203056360/
  • Rename "client_save" to "client_save_backup"
  • Start up DST
  • Start up new world

If that still doesn't work, then I would have to refer you to Klei Support here: https://support.klei.com/hc/en-us/requests/new

Discuss what the issue is and list the things you've attempted and also add the client and server log files. Sorry for taking a bit too long and not being much help on the matter.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
  • Create New...