[cod] Running CoD servers as a Linux Daemon

[MgA]RockCrusher RockCrusher at rogers.com
Sun Dec 5 14:49:21 EST 2004


Thanks Jay.  I was wondering about the use of Screen within a Daemon job. 

Any suggestions as to the run startup script for CoD is you don't use screen and use setusergid?
  ----- Original Message ----- 
  From: Jay Vasallo 
  To: cod at icculus.org 
  Sent: Saturday, December 04, 2004 12:07 AM
  Subject: Re: [cod] Running CoD servers as a Linux Daemon


  I do not use screen with daemon tools. The run file that you create, or your start script is monitored thru daemon. If the process is killed with a console command 

  \rcon quit, 

  the supervise process restarts the server. 

  If you have mutliple servers booting off of  main game installtion files, it is always wise to leave a server config in the main installtion. When the server starts it will use the main installtion server.cfg if the user's config is not present.

  If a client does not have a file or config properly edited or in the correct folder, the process will not restart. Always keep a server.cfg located in your main installation. 

  Example:

  Main installation server config at /games/cod/cod-server/uo/server.cfg

  User's server config at /home/user/cod-server/uo/server.cfg

  If configs are not present, I have seen the process take the whole cpu at 99%. 


  Daemontools is good program if installed correctly. Once installed, the program will create a folder called /service 
  cd /service

  Now create a folder and name it whatever the user is named.

  mkdir sbclan

  Now if you do the "ls" command, you will notice that there is now a folder called /service/sbclan/supervise 
  This is made by daemon tolls. Don't even bother with this folder. Let it be.

  Now you have to have created a start script and call it run. Copy the run file so it ends up as 
  /service/sbclan/run. The run file has have the setusergid command within the file . http://cr.yp.to/daemontools/setuidgid.html

  now "chmod +x run" and the service will start. you will also notice that the server has started.

  svc -d /service/sbclan  - will kill the server.
  svc -u /service/sbclan - will restart the server


  Once in a great while, I enter my ventrilo boxes and give the "ps aux" command to see all the processes. If a notice an error, i killed the process by thru daemon and search for the config error. After correcting the error, I would restart the process.

  I like using it, unlike many other people.

  cheers
    ----- Original Message ----- 
    From: Robert Mount 
    To: cod at icculus.org 
    Sent: Friday, December 03, 2004 10:28 PM
    Subject: Re: [cod] Running CoD servers as a Linux Daemon


    > You can run them on deamon tools

    Does deamontools let you monitor a screen process?  I've tried Cron and ended up with multiple server instances (periodically, like one extra server per day or so).

    --Rob

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://icculus.org/pipermail/cod/attachments/20041205/ec1ef079/attachment.htm>


More information about the Cod mailing list