Xonotic Forums

Full Version: Failed to read CFG file
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have been trying to set up a dedicated server but it refuses to read the server.cfg file. I have tried putting it in every location i could think of, but to no avail. Is there any thing I could do to fix this?

Also I'm wondering if the server poses a threat to network security
By default, if the server.cfg isn't placed right, you should get an explicit message:
Server Console Wrote:You have not written any server.cfg file yet.
The server will therefore run at default settings.

For information on how to set up a dedicated server,
look at the files in the server/ subdirectory of your
Xonotic install.

Is this the message you get? How do you start your dedicated server?
More importantly, have you read the readme in the server directory?
You need to put the server.cfg into your $userdir/data.
For linux that's something like /home/griff/.xonotic/data/
On windows it should be at My Documents/My Games/Xonotic/data
Then start the dedicated.bin or exe with +serverconfig server.cfg
I can provide you some simple scripts to manage servers on linux using the screen app if you like.
Start the dedicated server using the shell script. server_windows.bat for windows. And read the readme.
I don't know much about windows batch files but if I read it correctly he has to place the server.cfg into his installdir's data for server_windows.bat to work. So forget about what I said earlier about userdirs if you go that way.
Yes, exactly. server.cfg should be modified and placed into a data root directory, and the dedicated server should be launched using the script (or at least using the commandline parameters from the script)
Would "which server.cfg" show if the server is actually reading a server.cfg?

>Also I'm wondering if the server poses a threat to network security
Which network - clients, the servers, or even the servers hosts network? How would Xonotic threaten anybody's security? (maybe if they overdose on lines of coke Tongue)
Read the console log, if you get the message that I copied above it means that the server loaded the placeholder server.cfg from the data pk3, which means you need to override that with a proper configuration in the data dir.
overwrite the server.cfg from the data and use the right startparameter .. here an linux examble.
./xonotic-linux32-dedicated case "$(uname -m)" in x86_64) executable="xonotic-linux64-dedicated" ;; *) executable="xonotic-linux32-dedicated" ;; esac +serverconfig server.cfg
Why would he overwrite it? It's in the data pk3, isn't it? He just needs to put a server.cfg in a data directory and it will take priority over the one in the data pk3.
(03-23-2012, 02:14 AM)Mr. Bougo Wrote: [ -> ]Why would he overwrite it? It's in the data pk3, isn't it? He just needs to put a server.cfg in a data directory and it will take priority over the one in the data pk3.
* Spaceman agrees with SexyBougo Heart
It ends up that windows was installed on my laptop after it was repaired. In windows a command line window opens for dedicated server so I don't need to change CFG anymore. Thanks for taking time to answer though Smile