View previous topic :: View next topic |
Author |
Message |
theWeird
|
Posted: Sat Feb 20, 2010 6:37 am Post subject: Debugging server startup |
|
|
Hey there
I have some trouble running a savage XR server on linux.
The command line that is executed by GC client is this:
/home/gameserver/gamecreate/savage/server set config_port 11235
If I run this command by hand in SSH console everything works fine.
Server starts and is ready to be used.
But if I try to start the server in GC Controlpanel there are always this lines in my error log:
Start GameCreate attempted to start Weird Savage. 02/19/2010 21:30:37
Stop GameCreate stopped Weird Savage. 02/19/2010 21:30:34
Fail Process failure (Server crashed?) 02/19/2010 21:30:34
Start GameCreate attempted to start Weird Savage. 02/19/2010 21:30:13
Ok, it is possible to run GC client in foreground mode.
Using this I checked that the command that is ran by the client is correct.
But is it possible to run GC client in a kind of 'advanced debug mode'?
If there appears anything like an error using the startup command for the savage server I'd like to know which error it is so I could be able to fix it. |
|
Back to top |
|
 |
adbot
|
Posted: Thu Mar 31, 2011 3:57 am |
|
|
|
|
|
Andrew Mammoth
|
Posted: Sat Feb 20, 2010 1:25 pm Post subject: |
|
|
Try running the game using a screen, via Game Configuration.
Also, manually start the server using the same Command Line found via Server Overview, see what happens. |
|
Back to top |
|
 |
theWeird
|
Posted: Sun Feb 21, 2010 1:10 am Post subject: Re: Debugging server startup |
|
|
Already tried:
theWeird wrote: |
The command line that is executed by GC client is this:
/home/gameserver/gamecreate/savage/server set config_port 11235
If I run this command by hand in SSH console everything works fine.
Server starts and is ready to be used. |
I also tried running in screen via game configuration, did not work.
The server's binary only works if it is started directly from its directory.
If I run the command above from directory /home/gameserver/gamecreate/savage the startup works fine. But if I run it from a directory like /home/gameserver/gamecreate the server binary can't load required libs in it's libs directory.
So I wrote this startup script to ensure that the Binary is started from the right location and named it /home/gameserver/gamecreate/savage/server:
#!/bin/bash
cd /home/gameserver/gamecreate/savage
./silverback.bin $*
As I wrote in my first post startup using the same command as GC uses works fine from any directory in the server (using your beta client, checked the command in foreground mode) but GC's startup still fails. |
|
Back to top |
|
 |
Andrew Mammoth
|
Posted: Sun Feb 21, 2010 12:39 pm Post subject: Re: Debugging server startup |
|
|
theWeird wrote: |
The server's binary only works if it is started directly from its directory.
If I run the command above from directory /home/gameserver/gamecreate/savage the startup works fine. But if I run it from a directory like /home/gameserver/gamecreate the server binary can't load required libs in it's libs directory.
So I wrote this startup script to ensure that the Binary is started from the right location and named it /home/gameserver/gamecreate/savage/server:
|
That should not be necessary; GameCreate switches to the /gamecreate/savage directory before it runs the 'server' executable. It never starts the game server from its 'gamecreate' directory.
Quote: | As I wrote in my first post startup using the same command as GC uses works fine from any directory in the server (using your beta client, checked the command in foreground mode) but GC's startup still fails. |
I think you should choose 'Require screen' for the game; and make sure you are running the Client beta (you can see the version information in GC Client when it starts up).
After you Start the server via GameCreate; immediately open the screen session that was just started.
You should then hopefully see what the server console is saying, to help point to the reason for the server failure. |
|
Back to top |
|
 |
theWeird
|
Posted: Mon Feb 22, 2010 2:00 am Post subject: |
|
|
I am using your beta version of GC client in your sticky post in this forum.
After setting the game to 'require screen' and starting the server I tried to open the Screen:
screen -r Weird\ Savage
Cannot open your terminal '/dev/pts/5' - please check.
So I checked /var/run/screen/S-gameserver/ for running screen sessions.
There is no session created for the Savage server. Only the 4 instances of Teeworld.
I Re-Started the server and checked the screen dir again, no session for the savage server.
screen -r
There are several suitable screens on:
16596."Weird Ballworlds" (02/21/2010 04:58:33 PM) (Detached)
28306."Weird Waterworlds" (02/20/2010 05:08:26 AM) (Detached)
28295."Weird Testworlds" (02/20/2010 05:08:17 AM) (Detached)
28279."Weird Teeworlds" (02/20/2010 05:07:50 AM) (Detached)
Type "screen [-d] -r [pid.]tty.host" to resume one of them. |
|
Back to top |
|
 |
Andrew Mammoth
|
Posted: Mon Feb 22, 2010 7:56 am Post subject: |
|
|
Does Failure Reports report anything? |
|
Back to top |
|
 |
theWeird
|
Posted: Mon Feb 22, 2010 8:44 pm Post subject: Re: Debugging server startup |
|
|
still the same:
theWeird wrote: | But if I try to start the server in GC Controlpanel there are always this lines in my error log:
Start GameCreate attempted to start Weird Savage. 02/19/2010 21:30:37
Stop GameCreate stopped Weird Savage. 02/19/2010 21:30:34
Fail Process failure (Server crashed?) 02/19/2010 21:30:34
Start GameCreate attempted to start Weird Savage. 02/19/2010 21:30:13 |
|
|
Back to top |
|
 |
Andrew Mammoth
|
Posted: Tue Feb 23, 2010 9:44 am Post subject: |
|
|
If you can provide SSH access to me to investigate, and the URL to your GC panel, I can investigate further if you like.
It's a bit hard to do over a forum. |
|
Back to top |
|
 |
Andrew Mammoth
|
Posted: Thu Feb 25, 2010 10:26 am Post subject: |
|
|
I've had a look for you, its working now.
The problem appeared to be that when the SCREEN session was started, savage could not read the $HOME environment variable (the SCREEN has no environment variable passed to it called $HOME).
This caused the screen to be started, and Savage to be started, but savage immediately quit:
Quote: |
Starting
System_Init()
Unable to create .savage directory in your home directory location, bailing out.
|
I captured this by replacing the server script with a shell script that paused after the process exited.
This lead me to believe it wanted access to the $HOME environment variable (it was empty).
I replaced the server exe with this (and named server to server_real):
Quote: |
#!/bin/sh
HOME=/home/[your path]
export HOME
./server_real $@
|
The server is now online and pinging. |
|
Back to top |
|
 |
theWeird
|
Posted: Fri Feb 26, 2010 6:44 pm Post subject: |
|
|
Wow, thank you very much!
Savage is working great now! |
|
Back to top |
|
 |
|