Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Sep 2003
    Location
    Canada
    Posts
    120

    Default How to Install/Configure Remote cPgs Server?

    Hey there,

    Been going over the forums here for last few hours and the documentation here and have yet to find enough info to help us get our remote server up & running, thought maybe there'd be a sticky or sumptin

    At anyrate we've got a CentOs 4.6 remote box that we'd really like to get hooked up with our CentOs 4.6 WHM/cPanel box.. So any input on server requirements/spec, installation steps or cPgs configuration is welcomed and appreciated.

    Cheers..
    Buck-Host, Hosting that starts at just a buck $1
    MaxKombat the Gaming Cafe

  2. #2
    Member viraj's Avatar
    Join Date
    Sep 2006
    Location
    India
    Posts
    209
    cPanel/Enkompass Access Level

    DataCenter Provider

    Cool

    Hi,

    There're no problems in installing cPanel Game Servers on CentOS 4.6 boxes..

    ==================================================================

    ###################################################################
    Basic Requirements for cpgsd
    ###################################################################
    gcc
    perl 5+
    Net::SSLeay perl module
    IO::Socket::SSL perl module

    Versions 0.4.0 and later, cPGS uses a server/client mechanism. This allows cPGS
    to control gameservers running on remote machines (without cpanel installed)
    so as to elliminate any overhead of running cPanel itself on the same server
    the gameservers will run on. Every game of every user has a unique configuration
    for the remote server. Note that if you wish, you may run the cpgsd daemon on the
    local machine alongside cPanel, in which case you will use the loopback IP 127.0.0.1
    for all user's connections.

    Things you need to do:

    1) Run the `install` script provided in the cPGS gzipped tarball on the cPanel server(s).

    2) On any remote gameserver machines, run the cpgsd_install script. If only using the cPanel machine,
    run this script on there as well as the `install` script.

    3) On any remote gameserver machines, set up the config file (/var/cpanel/cpgsd.cfg) (this applies to the cPanel machine if only one server is used)

    Values are:
    secret: the shared secret key/pass you will use between servers. Be sure this value is the same on any servers involved in cPGS
    root: the base directory for cpgsd files (/var/cpanel/ by default)
    allowedips: comma delimited list of IP addresses that are allowed to talk to the daemon server
    sslpem: the SSL PEM file to use. This can be generated by the cpgsd_install script
    globalconf: location of the global config file that holds the locations of each gameserver file
    port: port that cpgsd listens on. do not change if at all possible. (2092 by default)

    4) Start up the cpgsd.pl daemon on any gameserver boxes. For example:

    /var/cpanel/cpgsd.pl

    This will log data to /var/log/cpgsd.log . You can change the log file by editing /var/cpanel/cpgsd.cfg and setting the logfile= variable.

    5) Log into WHM on the cPanel machine and begin configuring the users you want to allow to run gameservers.
    The "core config" option is where you will enter the IP address of the remote gameserver box for that user and the
    particular gameserver you select. A user can have an UT2004 server running on 1.2.3.4, while having a HLDS server running
    on 5.6.7.8, for example.

    IPs (that the user's server will be allowed to bind to on the gameserver machine) and Ports for each user/game should be
    self explanitory.

    Note that from 0.6.0+, it is now possible to run multiple types of the same type of game under one account. For example, "userabc" can run a CS:S server
    on 1.2.3.4:27015 , another CS:S server on 1.2.3.4:27025, a CS 1.6 server on 1.2.3.4:27018 and an ArmyOps server on 3.4.5.6:7617 .

    6) Log into the user's cPanel account and configure the gameserver, start it up and, assuming all is well, play

    *notes*
    --> if you do not have the perl module IO::Socket::SSL , you will need to install it on all servers involved ( perl -MCPAN -e'install IO::Socket::SSL' )
    --> if you do not have `wget` installed on the remote cpgsd.pl servers, you will need to in order to download and install gameserver packages from WHM

    ###################################################################
    Username Mapping
    ###################################################################

    This is a very basic feature that allows "UserA" on the cPanel server to control gameservers
    on remote servers as whatever user you designate. For example, "drdoom" on the cPanel server
    could control CS:S on 1.2.3.4 as the user "malcom", Call of Duty on 1.2.3.4 as "mickey", and
    Savage on 5.6.7.8 as "janky". Remote usernames may be configured in WHM with each user/game.

    ###################################################################
    Automatic restart on reboot
    ###################################################################

    *NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE*
    In version 0.4.0, this is disabled and will need to be rewritten to run
    on the remote gameserver machines.
    *NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE**NOTE*

    When a client starts any of the gameservers, it adds the server name into
    /var/cpanel/gameserv.restart and the command line used to
    /var/cpanel/gameserv_saved/$user_$game_$installnum

    The actual restart script, /usr/local/cpanel/bin/cpgs_chk , reads through all
    the users with gameservers installed and reads the ".restart" file.
    If the restart script can find the command line it needs to restart the gameserver,
    it will drop privileges to the user and try to start it. Currently the script does
    no checking to see if the server is running already or not, so it is advised
    not to run it unless it's directly after a reboot.

    Currently this script is not added to the init system since it has not been thoroughly tested.
    It is suggested you add it to the rc.local, local.start, etc file (depends on the distro) to have
    it run after the server reboots if manually running it is not feasible.

    ###################################################################
    Unique command lines per user/game
    ###################################################################

    If the admin has declared a custom command line (looks for existence of
    /var/cpanel/gameserv_saved/$user_$game_$installnum_useuniq), then client's starting their
    game server will always use the custom command line, regardless of what the
    client changes it to. This is mainly useful to allow special mods that are
    not yet supported by cPGS directly and should only be used by those who
    understand what they are doing.

    ###################################################################
    Instructions for creating server installation files.
    ###################################################################

    If you do not need or know how to create a custom gameserver package, then you
    may prefer to use the existing packages available from a mirror site.
    Please see http://cpgs.cpanel.net/ for a list of mirrors.

    Each server's installation is somewhat different. The way the installer is set up allows
    for the main server admin to create a default game server environment that will be applied
    to all new accounts, including patches, additional maps and other mods. The format for this is as
    follows:

    -Savage-

    Install from CD, by default into /usr/local/games/Savage/. To create a default installation file,
    you would simply tar/gzip it up and place it into the 3rdparty directory:

    cd /usr/local/games
    tar cjvf Savage.cpgs Savage
    mv Savage.cpgs /home/gameserver_files/


    *note that you can install the game on any linux machine and transfer the install file to other
    servers.

    -UT2004-

    Install from CD, by default into /usr/local/games/ut2004/. Apply the same method as the Savage
    server:

    cd /usr/local/games
    tar cjvf ut2004.cpgs ut2004
    mv ut2004.cpgs /home/gameserver_files/

    -Half-Life-

    Create a "Steam" account from http://www.steampowered.com/ and download the gameserver. You will
    probably need to update the steam client. After that you can download the various mods. currently
    support Half-Life mods are: Counter-Strike, Day of Defeat, Team Fortress Classic, Death Match
    Classic. Once you have these mods downloaded, you can package the directory:

    cd /path/to/gamserver
    tar cjvf hlds.cpgs hlds_l
    mv hlds.cpgs /home/gameserver_files/

    Alternately you can have clients create their own "Steam" accounts and install to
    $HOME/.gameservers/hlds_l/ . Currently all support mods should be installed. WHM controls
    in future versions will provide control over which mods are allowed.
    Clients can always install other mods and run them from the shell (if given shell access and
    permissions) if they desire.

    -Half-Life 2-

    The exact same as Half-Life with it's own mods.
    cd /path/to/gameserver
    tar cjvf hl2.cpgs hl2
    mv hl2.cpgs /home/gameserver_files/



    ###################################################################

    From within WHM you should find at the very bottom of the menu on the left a link to the
    gameserver control where you can control how many players and which type of servers are allowed.

    Clients can admin the servers they have access to from the GameServers link in the "x", "x2" and "gs" themes.
    The "gs" theme only provides cPGS support for strictly gameserver-only accounts.

    https://server.com:2083/

    For all questions, suggestions, and bug reports, please email darren@cpanel.net
    ==================================================================

    Courtesy

  3. #3
    cPanel Staff
    Join Date
    Dec 2001
    Location
    Houston, TX
    Posts
    1,846

    Default

    In the changelog I mentioned the inclusion of a new feature in WHM that lets you install a remote server from within WHM, "Install Remote Server". It's not been tested as thoroughly as I'd like, so if it doesn't work for you, open a ticket so I can take a look at what is breaking.

  4. #4
    Member
    Join Date
    Apr 2003
    Posts
    40

    Default

    am afraid I just manually installed the gameserver on remote server without cpanel

    took the files from cpanel server and upped them on remote and installed from there, installing a gameserver now, seems the cpanel server is able now to install without errors ...

    we will test once installed ....

  5. #5
    Member
    Join Date
    Sep 2003
    Location
    Canada
    Posts
    120

    Default

    Hey there viraj,

    hmm.. I've a doc very similiar this doc b4, just can't remember where I had found it, thank's so much for making your post we've at least got the connection going now and are able to do some testing

    Cheers..
    Buck-Host, Hosting that starts at just a buck $1
    MaxKombat the Gaming Cafe

  6. #6
    cPanel Staff
    Join Date
    Dec 2001
    Location
    Houston, TX
    Posts
    1,846

    Default

    That file is the readme, it's linked to on the main http://cpgs.cpanel.net website in the documents section

    http://cpgs.cpanel.net/GameServerAddon/readme.txt

    It's also quite a bit out of date, but should be updated once I get a few more of these ideas put into action.

  7. #7
    Member
    Join Date
    Sep 2003
    Location
    Canada
    Posts
    120

    Default

    ooops

    Cheers..
    Buck-Host, Hosting that starts at just a buck $1
    MaxKombat the Gaming Cafe

Similar Threads & Tags
Similar threads

  1. How to install cpgs on my web server!!
    By elmerz_com in forum cPGS Discussions
    Replies: 3
    Last Post: 01-06-2011, 07:34 PM
  2. Install Remote Server
    By MethOd63 in forum cPGS Discussions
    Replies: 4
    Last Post: 12-18-2009, 02:55 PM
  3. cPGS remote from cPanel server (different datacenters)
    By amclint in forum cPGS Discussions
    Replies: 1
    Last Post: 08-07-2008, 01:00 PM
  4. How can i uninstall cpgs on a remote server?
    By erythro in forum cPGS Discussions
    Replies: 1
    Last Post: 04-28-2008, 11:39 AM
  5. Problems to configure remote mysql server in one server cpanel
    By deicox in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 04-15-2004, 07:48 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube