LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-20-2005, 08:38 AM   #1
stuartmunro
LQ Newbie
 
Registered: Jun 2003
Posts: 17

Rep: Reputation: 0
Dedicated Server Run Terminal all the time


Hi,

I have a dedicated server for hosting call of duty (game), the server is in a remote location:

Quick spec:
CentOS 3.5
Webmin + DirectAdmin
P3 733MHz
128MB RAM + 512MB Swap
cod_lnxded patched v1.5

I use ZOC ssh terminal (windows) to control the server, the problem is I when I close zoc or disconnect the ssh session ends!of course, turning the game server off!!. But this is no good for a 24/7 dedicated game server, as my pc is not always on, to keep the session on.

What I would like to do if possible is:

1. Automatically start the server on BOOT UP using this command

./cod_lnxded +set dedicated 2 +exec server.cfg

Then when the server console is up and running I need to do this:

pb_sv_enable
g_gametype sd
map mp_carentan

And that allows users to connect.

Is there a way of setting up once and never doing again?

Many thanks
 
Old 06-20-2005, 12:06 PM   #2
jcspray
Member
 
Registered: Mar 2004
Location: York, UK
Distribution: Ubuntu
Posts: 132

Rep: Reputation: 15
I think that's a redhat derivative you're using, so you can put commands to be executed at bootup in /etc/rc.local (I think you might have to chmod +x /etc/rc.local).

As for running those commands once the game server has started, that's going to be specific to the game: perhaps there is a command line option that will let you put the commands that you want to execute into a file and have the game server run all the commands in that file?
 
Old 06-20-2005, 12:15 PM   #3
stuartmunro
LQ Newbie
 
Registered: Jun 2003
Posts: 17

Original Poster
Rep: Reputation: 0
The commands to set the game type I will only need to do once,
the real problem is when I exit zoc the ssh session ends and the game server
is turned off!!

I just want to be able to run the process without having zoc open all the time.

Thanks
 
Old 06-20-2005, 09:21 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,260

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
As jcspray said, try adding cmds to /etc/rc.local if it exists.
If not, use this sequence:

nohup <yourcmdhere> &

which will run the game in the background and tell it not to terminate when you logout.
 
Old 07-23-2005, 11:31 PM   #5
NYfanrules
LQ Newbie
 
Registered: Jul 2005
Posts: 6

Rep: Reputation: 0
I have that same problem the game server times out when I close the page in webmin and that command nohup doesnt work for me I dont know why.
 
Old 07-24-2005, 07:42 AM   #6
metaldude
LQ Newbie
 
Registered: Jul 2005
Distribution: Debian
Posts: 4

Rep: Reputation: 0
Just try putting the & symbole after it

For Example:

ping localhost &

that always worked for me.
 
Old 07-24-2005, 04:38 PM   #7
NYfanrules
LQ Newbie
 
Registered: Jul 2005
Posts: 6

Rep: Reputation: 0
I tried that but it only stays up for about like 1-2 min's
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dedicated Server Distros (SME server and Censornet) Sugga Linux - General 2 09-22-2005 04:15 AM
How to run MP3 file thru Terminal in K.D.E or Terminal itz2000 Linux - Newbie 5 08-04-2005 10:49 PM
is it possible run 2 cisco vpn clients at the same time on the same server cccc Linux - Security 2 02-25-2004 03:59 PM
Trying to run a half-life dedicated server Trd79 Linux - Software 0 01-08-2003 08:37 AM
where to get UT dedicated server dkc_ace Linux - General 2 12-19-2002 08:11 AM


All times are GMT -5. The time now is 08:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration