PDA

View Full Version : The "rcon quit" command


Salman
08-24-2003, 08:35 AM
U all know the rcon quit in console, it SHOULD boot your server pc, but if i do it the server goes down :p . Now how u do it that it reloads the server instead of quiting it :D

Salman

The_Jackal
08-25-2003, 02:33 AM
"RCON RESTART" or "RCON RELOADMAP"

Salman
08-25-2003, 03:40 AM
No u dont understand, RCON QUIT, that it reloads everything, like u do the command ./mohaa_lnxded ........ that it completely restarts server. I dont ask rcon restart or rcon reload_map, i ask RCON QUIT, how to do it that it reboots server

The_Jackal
08-25-2003, 04:32 AM
LOL 8O
Your use of the word "server" led me to believe you were referring to the game and not the machine.

I have no extensive experience with dedicated servers. But as far as I can tell "rcon quit" will NOT reboot your server PC. Rather it exits the game.

Rebooting of the PC requires the use of external commands, that of which is not available in the game coding.

I think you can have that command tagged and executed via a HTML link. Just an idea off the top of my balding head.

Hope this points ya in the right direction.

Salman
08-25-2003, 05:36 AM
the jackal, r u dumb or just acting like that? i'm not talking about booting the WHOLE SERVER, but the GAME SERVER

thank u

The_Jackal
08-25-2003, 07:25 AM
OK you darn Democrat! That's it! I am now mad! :twisted:
lol :D
Dude, I know my comprehension is A+.

Please define "WHOLE SERVER" and "GAME SERVER". In my first reply I assumed you were referring to the game engine as the server. But that did not seemed to be it. So I thought, he meant the PC itself - since the word BOOT ideally refers to the process a PC goes thru viz a viz powering up.

Perhaps, I am really dumb - perhaps. But I just don't know what you want. Do you? Please explain if you want help!

P.S. Are you related to Salman Khan? :rolleyes:

greensha
08-25-2003, 07:52 AM
Here's a little linux script that will reboot the mohaa game server after its been down for 30 secs.

[code:1]#!/bin/sh

while true; do
./mohaa_lnxded +set dedicated 1 +set developer 2 +set logfile 3 +set g_logsync 1 +set net_ip 66.66.66.66 +exec server.cfg
sleep 30;
done[/code:1]

Salman
08-25-2003, 08:09 AM
tnx greensha, where do i have to put that script?? :oops: and what name should i give it?

greensha
08-25-2003, 08:27 AM
make a text file paste that code into it (obviously add your mohaa command line) and save it as mohaa.sh. Put the file mohaa.sh into your mohaa directory. Now instead of starting mohaa via normal command line just type
./mohaa.sh

Script will start the server and restart the server if you quit.

Brian
08-27-2003, 07:58 PM
If you are running the dedicated server and running it on a windows machine you can run the game as a service. When you do a rcon quit command the OS thinks the service crashed and reboots it.

Salman
08-28-2003, 05:14 AM
dont know if u know, but no one is gonna run a mohaa_lnxded on a win 2k system. I couldnt get that "script" to work yet, gonna try it one more time.

greensha
08-28-2003, 08:05 AM
OOPS sorry about that I thought you were running linux system. I guess I should have asked that question first.

On a win2k system you have to set up the dedicated server exe as a process/service that win2k will reboot once it detects shutdown.

Sorry about that again, I work strange hours and it really messes me up.

SNYPE
08-28-2003, 10:21 AM
Salman, as BBates says you need to run the game as a Service in Windows to make it do what you want it to. Theres a great program for this called FireDaemon. The Lite version is free and runs a single service only (which is all you need for serving 1 game). They have HowTo documents for setting up UT game servers that you can use for an example.
http://www.firedaemon.com/

Salman
08-28-2003, 05:57 PM
uhm? am i the only one that understands english??

THE SERVER RUNS ON A LINUX SYSTEM

greensha
08-28-2003, 06:15 PM
dont know if u know, but no one is gonna run a mohaa_lnxded on a win 2k system. I couldnt get that "script" to work yet, gonna try it one more time.


Dam Im confused. Well now that we have that cleared up. What is going on when you try the script.

Salman
08-28-2003, 07:40 PM
to be honest:

the server keeps doing the config. So, it starts server , it starts server, it starts server. . . thank god i noticed, it already started 15 then i killed the process so. We need a script, that IF it sees the PID has crashed of mohaa, that it looks at it and launches it again :) that's all now, how u make it,

SNYPE
08-28-2003, 08:26 PM
Please be more descriptive next time, it helps us help you.
Try this:
http://www.mohadmin.com/nuke/modules.php?name=Content&pa=showpage&pid=21

Salman
08-28-2003, 08:33 PM
tnx alot SNYPE. So these two .SH files must be put in the mohaa dir right??

greensha
08-28-2003, 10:53 PM
The script i posted works fine. The key to my script is the screen utility. Start screen / switch to location of mohaa (eg /usr/games/Mohaa/)
start script ./moh.sh (detach screen ctrl +A +D). type ps -x you will now see screen , moh.sh , mohaa_indexed all running. If mohaa_indexed is quit or crashes the script restarts the server. It checks every 30 secs. If your not using the screen utility my script or dogmeats will not work correctly.

The other option is the & symbol at the end of a command which will background a process.

Salman
08-29-2003, 06:26 AM
The other one also doesnt work. If i type:

/mlds.sh

the server starts, but keeps restarting restarting restarting .... over & over. The server runns, but with high ping, but when i close putty, server crashes. And if i start the game by the normal ./mohaa_lnxded ..... and i type rcon quit it also doesnt work. So litltle help?