SCInterface Quick Start Guide for Linux

From SCInterface Wiki

Jump to: navigation, search

This Quick Start guide is intended to provide a complete overview for getting SCInterface installed and running on a Linux based operating system. These guidelines can be applied for deploying SCInterface on various platforms and may vary from platform to platform. For instructions with working with Windows, please visit the SCInterface Quick Start Guide for Windows.

Attention SCInterface Evaluation, XL and XLS Users: View the SCInterface Eval, XL and XLS Setup wiki article prior to reading these instructions as most of the setup has already been done for you.

If you have any questions regarding this Quick Start Guide, please visit the SCInterface Forums and post your question to the community. Professional support is also available through Netarus Professional Services.

Contents

Overview

SCInterface is separated into three core components. All three components are required to be installed in order for SCInterface to function. These three components are:

  1. PHP Web Interface - The web interface is the way that administrators and end users interact with SCInterface. The web interface must run on any PHP compatible platform such as Apache compiled with PHP support or Xampp Which is Pre-installed with PHP Support.
  2. SCM - This is the core to SCInterface. The SCM can only run on a Linux or BSD based platforms and the SCM must be able to communicate with a PostgreSQL database.
  3. SC - This is the remote agent that is required to run on each platform that you wish for SCInterface to manage and control (including those applications running on the same server as the SCM and the UI).

Amoung these three core components, there are two core dependencies for SCInterface to function correctly. The SCM requires a PostgreSQL database and the PHP Web Interface requires a web server compiled with PHP support such as Apache HTTP Server (also known as Apache) or Xampp. Instructions for installing each of these core dependencies are included within Appendix A.

Each of the three SCInterface core components (SCM, UI, and SCs) can be run on the same system or on separate systems to allow for greater flexibility and control. This is ideal for implementing redundant and failover implementations of SCInterface as needed. However, fail-over and redudancy goes beyond the scope of this quick start guide.

Please refer to the Sensor - About SCInterface page or the Games - About SCInterface page for more information on the architecture and framework for your particular instance of SCInterface. For assistance with implementing these types of solutions, please refer to Netarus Professional Services.

Prerequisites

The following are the minimum prerequisites in order to use this quick start guide. The SCInterface installer will not function unless all of these prerequisites are met.

  1. This installer will only function on Linux. Although we wrote the installer to function on nearly every distro of Linux, here is a list of platforms that have been certified by our development team: Supported SCInterface Platforms
  2. For the UI and SCM, ensure that the following two core dependencies are installed.
    1. PostgreSQL - Should be installed on the same system where the SCM will reside.
    2. Apache - This is where the UI will run from. Use apt to make installation of apache and it's dependencies easier to install.
    3. yum, yast or apt should be installed to installing additional dependencies automatically. Click here for more information about using Linux Package Managers.
  3. Make sure that all of the SCInterface System Requirements have been met.
  4. The SCInterface system must be connected to the internet since certain dependencies are downloaded from the scinterface.com site automatically including your license.
    1. Confirming Linux Networking is Setup Properly
  5. Ensure that you are comfortable working within a *nix environment. This installation guide is recommend only for those that are comfortable using *nix platforms as it involves (un)tar'ing, downloading files, compiling sources and understanding the impact of running various services as root.
  6. The entire installation should take anywhere from 30 to 60 minutes depending on the speed of your platform, what components are already setup (i.e. database and web server) on the platform that is running SCInterface and the amount of experience you have working with Linux.

Things to Know Prior to Installation

The following is a simple check list that you should fill out prior to the installation. This will help when filling in the fields necessary to install SCInterface.

  1. Web server's HTML document root (i.e. public_html or htdocs or www folder)?
  2. Location of PostgreSQL database. The SCInterface will attempt to locate it on it's own if it is on the same system as the installer; however, if it can't, you may need to manually enter in the path to PostgreSQL. For easier installation, it is recommended that the SCM is installed on the same machine as the PostgreSQL database.
  3. Hostname or IP address of the system that will be running the SCM. This will function as your master server and where all of your SCs will connect.
  4. The SCInterface installer must be ran as root. This is to allow the system to create users and access the PostgreSQL database.

Obtaining the SCInterface Installer

The SCInterface installer is actually comprised of three separate installers that install each of the SCInterface core components (UI, SCM, SCs). By downloading the main installer, you can choose between installing all of the components or each one individually based on your own requirements.

Registering to Download the SCInterface Installer

You must obtain an '<installer_url>' for the SCInterface installer in order to install SCInterface on your platform. Go to:

http://www.scinterface.com/download

Existing customer can also login to the SCInterface support portal at http://support.scinterface.com and download the Linux installer.

Make sure to save this URL information as you will need it for the other components of SCInterface as well. Follow the instructions on the page and download the 'scinterface_install.sh' file to your Linux based platform.

Downloading the SCInterface Installer

Login as root onto your Linux based system and from the console prompt, type:

NOTE: You must be logged in as root

 cd ~
 wget '<installer_url>' -O scinterface_install.sh

Where '<installer_url>' is the download location of the scinterface_install.sh installer that you registered for in Registering to Download the SCInterface Installer above. Note the quotes in the wget command and the -O option.

If you did not receive the notice to download the scinterface_install.sh script, try this instead:

cd ~
wget http://download.scinterface.com/scinterface_install.sh

Invoking the SCInterface Installer

  • NOTE: The SCInterface installer must be ran as root. This is to allow the system to create users and access the PostgreSQL database.
  • After downloading the SCInterface installer into the home directory of your root user, the installer can be invoked by running:
 sh ./scinterface_install.sh

The following will appear.

########################################################################
########################################################################
Starting the SCInterface Installation Script
########################################################################
########################################################################


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

SCInterface is designed to be installed on one or more hosts. Please 
refer to the SCInterface Wikipedia at http://wiki.scinterface.com for 
documentation and setup instructions.  Please direct any questions to 
http://forums.scinterface.com

########################################################################
Press ENTER to continue


  • After pressing ENTER, the installer will attempt to search for any missing dependencies. If any of the dependencies do not exist, the installer will do one of the following:
  1. Try to install the dependencies automatically using a supported Linux Package Manager.
  2. Immediately stop as these dependencies will need to be installed before continuing.
  • The following text will appear if the required dependencies were found. Otherwise, the installer will indicate which dependencies need to be installed before continuing.
Verifying dependencies 

dig             : OK
wget            : OK
script          : OK
sed             : OK
grep            : OK
tr              : OK
checking network connectivity...
  • Next, the Welcome to the SCInterface Installer will appear to provide a quick overview of the three core components to SCInterface.
########################################################################
Welcome to the SCInterface Installer (vx.x)
Current Host: linux.scinterface.com


SCManager (SCM) - The heart and central control manager of the entire 
 system. This must be setup on at least one host.
   The SCM is not currently installed

Web User Interface (UI) - The interface to the entire system, accessible 
 over web browser. It must be installed on at least one host.
   The UI is currently installed : version 1.6

SController (SC) - The controller component of the system.  It should be 
 installed on each host that you wish to control via SCInterface
   The SC is not currently installed

########################################################################
Press ENTER to continue
########################################################################
  • Make note of the Current Host: field. This field will need to match the hostname that you fill in for when you added the SC to the web interface under Adding the SC to the SCM.
  • After pressing ENTER, the installer will check for previously installed versions and prompt for choosing an installation type.
########################################################################
UI:     Not Installed
SCM:    Not Installed
SC:     Not Installed

Selected components are labeled with I, R, or U
[I] = to be installed/reinstalled
[R] = to be removed
[U] = to be updated
[ ] = do nothing

Select components by entering a component name prepended by a '+'
Remove components by entering a component name prepended by a '-'
  example:  +SCM -SC   (will remove the SC and add the SCM)

When you are satisfied, type 'done' to continue

 [I] UI
 [I] SCM
 [I] SC
########################################################################

 > 
  • At the > prompt, the installer will to determine which components you have already installed on the system. By default, the SCM, SC and UI will be selected to install by having an I in the [ ] boxes if the installer does not detect them. The syntax for the installer is as follows:
    • To remove any component, simply type -XX (where XX is either UI, SCM or SC) at the > prompt and press ENTER. You may have to repeat this process until an R is next to the component you wish to remove.
    • To add any component, simply type +XX (where XX is either UI, SCM or SC) at the > prompt and press ENTER.
  • If you wanted to only install the SC on this system, at the > prompt type:
 > -UI -SCM

...to remove the I (install) option from the UI and SCM. The screen would then look like this:

########################################################################
UI:     Not Installed
SCM:    Not Installed
SC:     Not Installed

Selected components are labeled with I, R, or U
[I] = to be installed/reinstalled
[R] = to be removed
[U] = to be updated
[ ] = do nothing

Select components by entering a component name prepended by a '+'
Remove components by entering a component name prepended by a '-'
  example:  +SCM -SC   (will remove the SC and add the SCM)

When you are satisfied, type 'done' to continue

 [ ] UI
 [ ] SCM
 [I] SC
########################################################################

 > 
  • Notice that only the SC would be installed in this case.
  • Additional syntax arguments include upgrading (U) and removing (R) SCInterface components. If the installer detects that a component is already installed and you choose to Install that component again, the installer will automatically move to Ugrade for that component.
  • For the purposes of this guide, we will be installing all three SCInterface core components by having an 'I' in each of the boxes next to the UI, SCM and SC. So the installer should look like this:
########################################################################
UI:     Not Installed
SCM:    Not Installed
SC:     Not Installed

Selected components are labeled with I, R, or U
[I] = to be installed/reinstalled
[R] = to be removed
[U] = to be updated
[ ] = do nothing

Select components by entering a component name prepended by a '+'
Remove components by entering a component name prepended by a '-'
  example:  +SCM -SC   (will remove the SC and add the SCM)

When you are satisfied, type 'done' to continue

 [I] UI
 [I] SCM
 [I] SC
########################################################################

 > 
  • To start the installer once all the appropriate components are selected, type done and press 'ENTER'.

Accepting the License Agreement

The license will appear shortly after configuring the installation options. Press the 'SPACEBAR' or the 'ENTER' key to increment between the pages. You must type yes and press 'ENTER' at the end of the scrolling license agreement before the installer will continue any further.

Next, you will be prompted for the appropriate settings and parameters for the UI, SCM and SC. Since everything is being installed on the same server, we will accept the defaults.

The SCInterface installer will now download the necessary dependencies from scinterface.com for each SCInterface core component and install them onto your system.

Installing the PHP Web Interface

Assuming that the Linux scinterface installer (sh file) has been started, start by choosing the UI option. This will install the PHP Web Interface. Make sure that Apache with PHP Support has been compiled before continuing. The default settings can be accepted which will:

  1. Create a new user called uiuser. This will be the user that will spawn the web interface within Apache
  2. Copy the neccessary HTML and PHP files to the uiuser's home directory.

Additional References:

Installing the Linux SCM

By choosing the SCM option, the SCM installer will automatically begin after the PHP Web Interface installer. The following describes the process of installing the SCM.

  • When prompted, leave the following on their default values. Press [ENTER] will leave the default values.
    1. What is the hostname of database server?
    2. On which port does this database server listen?
    3. What is the username configured in the database server for SCInterface?
      In particular, make sure the database user is scmuser. This is important for consistency and the postgresql user will be created automatically if it does not exist.
  • After confirming that PostgreSQL has been installed and that all dependencies are installed, the SCM installer will:
    1. Download the SCM Installer
    2. Extract the contents to your system
    3. Create and propagate the PostgreSQL database with SCInterface content
    4. Automatically start the SCM.
  • If you chose to install all three components (UI, SCM, SC), the installer will now go to install the Linux SC.

Additional useful references:

Installing the Linux SC

The last component to be installed is the SC, which is the remote agent that will control this system.

  1. If you have not already, invoke the .sh install script from the command-line.
  2. Once prompted, choose the SC to begin installing the SC. The setup will make sure that all dependencies are installed before continuing.
    1. If a dependency is missing, you will be prompted indicating the dependencies that should be installed.
    2. NOTE: Don't forget to add the SC to the SCM after installing the SC. The SC must be added to the SCM in order to the SC to start.
  3. After choosing to install the SC, a screen similar to below will appear:
########################################################################
### SC Installation Options ###
#
# We will now prompt you for installation options regarding the
# SCInterface Controller.  Just leave empty to accept the
# recommended defaults [in square brackets]
#
########################################################################
Please enter the hostname or ip address of the machine hosting the SCM
 [localhost] : 
And its port [51126] : 

The SController will be configured to connect to
the SCM located at localhost:51126.

Are these settings satisfactory? {y/n} : 
  1. Press y and ENTER to start the installation of the SC.
  2. If installing the SC on a server separate from the SCM, make sure that the hostname or IP address of the SCM is entered instead of localhost.
  3. After installing this SC on the same system as the SCM, you can repeat this process for deploying more SCs to other Linux based systems. For instructions with installing an SC on Windows, please view the SCInterface Quick Start Guide for Windows.

NOTE: Don't forget to add the SC to the SCM after installing the SC. The SC must be added to the SCM in order to the SC to start.

Post Installation Instructions

If both the SCM and SC have been installed, they will be automatically added to your init.d to ensure they are started automatically on reboot. The SCM will also be automatically started but the SC cannot be started until it is added to the SCM.

Configuring the Linux SCM

The Linux SCM can be configured by:

  1. Re-running the installation script choosing SCM. Fill out the new hostname and db username.
    -- OR --
  2. Edit /home/scmuser/runme.sh and look for hostname and edit the value

Starting the Linux SCM

The Linux SCM can be manually started at anytime by running the following from the command prompt (depending upon your distro of Linux):

service SCM start

OR

/etc/rc.d/init.d/SCM start

OR

/etc/init.d/SCM start

OR

The SCM can also be restarted manually by first logging in as root and then running the following commands:

su - scmuser
cd ~
./runme.sh start

If you are having trouble starting the SCM, please refer to the SCInterface Troubleshooting Guide.

After successfully starting the SC, now we will go to the section Accessing SCInterface for the First Time.

Reconfiguring the Linux SC

The installer has already already configured the SC to connect into the SCM. If you need to change these settings, the Linux SC can be reconfigured by either:

  1. Re-running the installation script choosing SC and fill out the new hostname and port.
    --OR---
  2. Edit /home/scuser/SController/runme.sh and look for hostname and port and edit the values.

Starting the Linux SC

NOTE: The SC cannot be started until it is added to the SCM. The following section is just a reference for later.

The Linux SC can be manually started at anytime by running the following from the command prompt (depending upon your distro of Linux).

service SC start

OR

/etc/rc.d/init.d/SC start

OR

/etc/init.d/SC start

OR

The SCM can also be restarted manually by first logging in as root and then running the following commands:

su - scuser
cd ~
./runme.sh start

If you are having trouble connecting into the SCM, please refer to the SCInterface Troubleshooting Guide.

Installation Cleanup

  • The installation logs can be removed from the tmp folder, which use the syntax of SCI_Install_Log_##########.log (where ########## is the unix timestamp for when the install log was created).
  • The scinterface_install.sh installer can be removed from the system.

Registering your SCM with SCInterface

IMPORTANT

If you are a licensed SCInterface holder, make sure you complete these steps. Otherwise, your installation will not be registered with our license server and your license will not be automatically renewed. Evaluation customers can ignore this step.

  1. Make sure that payment has been submitted through http://support.scinterface.com
  2. Evaluation customers can ignore this step. Licensed customers must register each SCM with SCInterface even if you reinstall SCInterface onto another system. The SCs do not need to be registered with SCInterface. Instructions:
    1. After installing the UI and SCM onto your system, login to your web UI as 'sysadmin' (default password is 'password').
    2. Click on the orange wrench icon next to your SCM on the 'At a Glance' page.
    3. On the overview page for the SCM, click on the link next to 'Upgrade or Renew License:'. This link will take you to http://www.scinterface.com/renew
    4. Select your platform (i.e. Games, Servers, Sensors, etc.).
    5. Enter in your contact information and the number of SCs that should be licensed for your SCM. Entering in more SCs than you are licensed will only delay your order.
    6. Once submitted, please allow 1 business day for us to increase your number of SCs licensed for use with your SCM. You will receive notification once your SCM has been successfully registered.

Next Steps

After successfully starting the SC, now we will go to the section Accessing SCInterface for the First Time.

Accessing SCInterface for the First Time

In order to access SCInterface, make sure that the following steps have been completed:

  1. The Web UI has been installed and Apache is running
  2. The SCM has been installed and is running
  3. The SC has been installed and is running

If you are having trouble accessing your UI, SCM or SC, please refer to the SCInterface Troubleshooting Guide.

The following steps provide an overview of how to access SCInterface for the first time and the steps that should be taken after installing all three components.

Connecting into the Web Interface

Once all three components are successfully installed on the same system, point a web browser to the IP address of the UI installation.

  1. If you accepted the default installation option for the UI, then you may need to point your browser to:
    http://myserver.com/~uiuser/scinterface/
    OR, if you have a web browser on the same system as the UI, type:
    http://localhost/~uiuser/scinterface/
    OR
    http://localhost/scinterface/
  2. SCInterface VMWare Appliance users should point their web browser to:
    http://localhost

This assumes that the UI was installed with the default settings as uiuser. You may have to change the directory accordingly to match your installation.

If you have successfully accessed the login page, you should see a login prompt as shown below:

Image:ui_login.jpg

Logging into the Web Interface

The initial username system administrator is:

sysadmin

The initial username system administrator is:

password

You should immediately go into the Admin->Users section and change this!

Adding the SC to the SCM

After logging in as the system administrator, make sure to add your SC running on your SCM to the system. To do this:

  1. Login as the system administrator
  2. Click the Admin tab
  3. Click the SControllers tab
  4. Click the Add New SC sub-tab
    1. You must have enough SC Credits available within your account in order to add additional SCs.
  5. Follow the prompts to add the SC to SCInterface. The important fields are:
    1. SC Name: - This can be a simple description of the SC
    2. Address: - This is the IP address of the SC (this should match the hostname of the SC when the SC was originally installed). This string is case sensitive!
      1. If your SC is running on the same system as your SCM, do not use localhost for the SC's address. Make sure to use 127.0.0.1 instead.
    3. Numeric IP Address: - Enable this field if using the IP address of the SC
    4. SConnector: - Make sure to choose the appropriate platform for the SC that it is running on.
  6. Click Add SC
  7. Once the SC has been added, the SC can be installed and the SC can now be started.
  8. Return to the At a Glance page on the Web UI and your SC should show a green light as shown below:

Image:ui_sc_online_sc.jpg

If you see a yellow light as shown below for your SC:

Image:ui_sc_offline.jpg

... you may need to troubleshoot the connection between your SC and SCM. Please refer to the SCInterface Troubleshooting Guide for additional assistance.

Adding Users

Add some users to SCInterface to allow differnet people to access your newly installed applications and devices by:

  1. Login as the system administrator
  2. Click the Admin tab
  3. Click the Users tab
  4. Click the Add New User sub-tab
  5. Enter in the users information
  6. Make sure to assign the user to a particular application (or even SCs for that matter if you would like for them to be able to manage the SCs themselves).

Adding a New Application or Device

Next, we will add a new application or device to the SC that we recently added.

  1. Login as the system administrator (sysadmin).
  2. Click the Admin tab.
  3. Click the Applications or Game Servers tab.
  4. Click the Add New App or Add New Game Server tab.
  5. Follow the step by step instructions for adding the new application or device to SCInterface.
    1. If applicable, the SCInterface Add New App wizard will prompt you to automatically install the application as well.

To reinstall the application:

  1. Go under the At a Glance tab (also know as the Config section of SCInterface)
  2. Locate the new application and click the Config button (looks like a wrench) next to the application
  3. Manual installation:
    1. Locate the Base Dir location of the application under the Overview tab.
    2. On the SC machine, manually install the application in the same directory as the Base Dir. Make sure that the executable is at the root of the Base Dir and not within a sub-folder after installing the application.
    3. Once the application is installed on the system, the Start and Stop buttons should function.
  4. Automated Installation:
    1. Select the Install option from the dropdown list of available commands.
    2. Click Execute.
    3. If available, the application and dependencies will automatically install onto the SC that this application belongs to.
    4. Once the application is installed on the system, the Start and Stop buttons should function.

NOTE: If SCInterface does not detect the executable for the application, the application will not start. The application must be installed in order for it to run.

For additional assistance:

Install Additional SCs

Need to add additional Windows and Linux systems into your SCInterface installation to control additional systems through the same interface? It is as simple as:

  1. Upgrading your SCInterface SCM License
  2. Installing the additional SC on each system
  3. Adding the SC to your SCM
  4. Starting the SC.

Basically:

  1. Installing Additional Linux SCs - Take the scinterface_install.sh to additional systems to install additional SCs and repeat the steps above for additional applications or devices.
    1. A very useful utility for installing these dependencies is apt, yum, yast and if you're running Gentoo use emerge.
  2. Installing Additional Windows SCs - Follow the SCInterface Quick Start Guide for Windows.

Platform Specific Tasks After Installation

Depending on your platform, you may wish to tune SCInterface for your environment. Please follow the following article for more information specific to your platform:

Getting Help With SCInterface

There are numerous options for obtaining support for SCInterface.. Here are some important links to reference:

Appendix A: Installing Dependencies

Installing PostgreSQL

View the HowTo: Install PostgreSQL SCInterface wiki guide.

Installing a Web Server with PHP Support

See HowTo: Install Apache.

Personal tools