Sending a "stop" or "quit" (or whatever works, I use quit) to the
console is good. A lot of people miss that and just send kill -9 to the
binary process (srcds_linux) and don't realize that the bash script
(srcds_run) will auto-restart the process via crash recovery.
However, it looks like the immediate next thing done in the script is to
kill the whole screen process, which would kill everything in it. There
is no wait between sending the quit command, so the server is not
cleanly quitting and clients are probably not being cleanly notified.
You need to give the server a little time to actually quit. At the very
least, put a "sleep 3" in there right after the "echo -n "Stoppe
$SCREENNAME" or something.
In my script, I send a quit, monitor the process for something like ten
seconds to verify that it actually quit, and then kill the whole tmux
(like screen) session. It's not a quick process because srcds servers
like to crash when "quit" is issued, which is awesome.
Anyway, this looks pretty reasonable.
Mike Johansen wrote:
By killing it I mean:
function stop_server {
if [[ `screen -ls | grep $SCREENNAME` ]]; then
echo -n "Stoppe $SCREENNAME"
kill `screen -ls | grep $SCREENNAME | awk -F . '{print $1}'| awk '{print
$1}'`
echo " ... done."
else
echo "Konnte den Screentab $SCREENNAME nicht finden"
fi
}
This is not my script, I got it from another site. And the host does not go
down, I never said that, it locks up. It's online, and the hardware has been
tested yesterday by the DC and they can report that the hardware is as
stable as can be. The only thing the logs show is the usual stuff, it does
not report anything useful in terms of the srcds locking up.
--
# Jesse Molina
# Mail = [email protected]
# Page = [email protected]
# Cell = 1.602.323.7608
# Web = http://www.opendreams.net/jesse/
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please
visit:
https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlds_linux