Advanced install (Windows)

FairCom installation procedures on Windows for experienced users

After the FairCom product is downloaded, the server can be installed using the downloaded compressed (zip) file or the Microsoft Installer file.

The compressed zip file is ideal for embedding the FairCom server into an application or running multiple instances of the server on the same computer.

The Microsoft Installer automatically installs dependencies and runs the FairCom server as a Windows Service.

Install with a zip file

  1. Download the FairCom server as a .zip file.
  2. Unzip the downloaded file into a root <faircom> folder — for example, c:\faircom\.

FairCom recommends using 7-Zip because other zip utilities have limitations on the number of files and paths that they can unzip.

 
  1. Run <faircom>/server/faircom.exe.

The evaluation version of the product times out after three hours and shuts down the server. Therefore, the server needs to be restarted every three hours.

 

Each time you restart your computer, you need to run faircom.exe to load the server.

This is ideal for an evaluation environment where you want full control over the server.

For a production environment, consider using the Windows installer to install FairCom as a Windows service that automatically loads the FairCom server each time the computer restarts.

 
 
 

Install with the Windows Installer

This procedure installs the FairCom server as a service that runs automatically when Windows starts.

  1. Download the FairCom server as a Windows Installer (.msi) package.
  2. Run the installer package.
 
 

Use setup.bat

The <faircom>/setup.bat file is a convenient way to configure the FairCom server.

The setup.bat file runs FairComConfig.exe. For more information on FairComConfig.exe, see Configure installed features using FairComConfig.exe.

 
  1. Run setup.bat to:
    • Configure specific drivers
    • Configure the FairCom server as a Windows service
    • Configure Java and firewall features
    • Remove all features.
  2. Follow the prompts on the installation window to configure or remove the selected options.

FairComConfig.exe installs the Microsoft Visual C redistributable file. However, if it is already installed, a Setup Failed error message will appear stating that a newer version of this file is already installed. This message can be ignored, and the installation can finish.

 
 
 

Silently install a Windows service

Follow these steps to do a silent, headless installation of a FairCom product on Windows.

  1. Install with a zip file
  2. From a command prompt, modify the following sc create command and run it.
sc  create  "FairCom-EDGE"  binPath= "C:\FairCom\FairCom-Edge.windows.64bit.v4.0.0.45\server\faircom.exe"  start= auto  error=normal  DisplayName= "FairCom EDGE Server"
  1. Update the binpath value in the sc create command to the path where FairCom Edge is installed.
binPath= "C:\FairCom\FairCom-Edge.windows.64bit.v4.0.0.45\server\faircom.exe"
  1. If "FairCom-EDGE" does not match the installed product, update it to match.
    1. For FairCom MQ, use "FairCom-MQ".
    2. For FairCom DB, use "FairCom-DB".
    3. For FairCom RTG, use "ctreeRTG".
  2. If necessary, update the start value to change how the service starts.
    • auto will automatically start the service when Windows starts. This is the recommended setting.
    • delayed-auto will automatically start the service when Windows starts but with a delay. There is rarely a reason to delay the start of a FairCom product.
    • demand requires that the service be started manually. It will not start automatically. This is recommended for a non-production environment when you want to control when the FairCom product runs.
    • disabled prevents the service from starting altogether. There is rarely a reason to use this setting.
  3. If necessary, update the error value to change how Windows behaves at startup if the service fails.
    • normal causes Windows to start normally when the service fails to start. When this happens, Windows shows the logged-in user a dialog box explaining why the service failed to start. This is the typical value for error.
    • severe causes Windows to restart using the last known good configuration when the service fails to start. This value can be used in a mission-critical environment when the computer only runs the FairCom product.
    • critical causes Windows to restart using the last known good configuration when the service fails to start. If the service fails to start again, Windows stops the bootup process. This value is not recommended for mission-critical environments since it requires administrative intervention.
    • ignore causes Windows to ignore the service's failure to start. This setting is not typically recommended because there is no indication that the FairCom product did not start.
 
 

Use sc.exe to manage a Windows service

This section provides commands for using sc.exe to create, remove, start, stop, query, and configure any Windows service.

Important

All sc commands must be run using an administrator account, meaning you must open the Command Prompt with Run as administrator.

 

Create a service

Create a Windows service to run FairCom Edge (See also Silently install a Windows service).

A space is required after binPath=start=, and DisplayName=.

 
sc  create  "FairCom-EDGE"  binPath= "C:\FairCom\FairCom-Edge.windows.64bit.v4.0.0.45\server\faircom.exe"  start= auto  error=normal  DisplayName= "FairCom EDGE Server"
 
 

Query service

Get the status of a FairCom Edge Windows service.

sc queryex fairCom-edge
 
 

Start service

Start FairCom Edge as a Windows service.

sc start fairCom-edge
 
 

Stop service

Stop FairCom Edge as a Windows service.

sc stop fairCom-edge
 
 

Delete service

Remove FairCom Edge as a Windows service.

sc delete fairCom-edge
 
 

Disable service

Disable FairCom Edge as a Windows service so that it does not run when Windows boots.

sc config fairCom-edge start=disabled
 
 

Start as a service automatically

Automatically start FairCom Edge as a Windows service when the computer restarts.

sc config fairCom-edge start=auto
 
 

Start as a service automatically with a delay

Delay starting the FairCom Edge as a Windows service when the computer restarts.

sc config fairCom-edge start=delayed-auto
 
 

Start as a service manually

Manually start the FairCom Edge as a Windows service rather than have it automatically start when the computer restarts.

sc config fairCom-edge start=demand
 
 

Change service description

Change the FairCom Edge Windows service description.

sc description fairCom-edge "FairCom Edge New Description"
 
 

Automatically restart the computer on service failure

When the FairCom Edge Windows service fails to start during a computer restart, this command automatically restarts the computer using the last known good configuration.

sc config faircom-edge error=severe
 
 

Notify the user when the server fails to start the service

When the FairCom Edge Windows service fails to start during a computer restart, this command causes Windows to show the user a dialog box explaining the failure.

sc config faircom-edge error=normal
 
 
 
 

Headless script to install a Windows service

FairCom provides a simple script that installs a FairCom product as a Windows service. It must be run as an administrator.

Before running the script:

  • Change the binPath to the <faircom> folder.
  • Change the name and description of the service if the product is not FairCom Edge.
  • This script assumes you have already downloaded and unzipped the FairCom product. It also stops and removes the service if it is already installed. This is useful when you need to remove a previous version of the product. It then creates a new service and starts it.
  • The service name is case-insensitive.
 

Important

If you use a different name for the service, be sure to change the service name in the script.

 
sc stop fairCom-edge
sc delete fairCom-edge

sc create  "FairCom-EDGE"  binPath= "C:\FairCom\FairCom-Edge.windows.64bit.v4.0.0.45\server\faircom.exe"  start= auto  error=normal  DisplayName= "FairCom EDGE Server"
sc start fairCom-edge
 
 

Run multiple instances

  1. You can run multiple instances of FairCom on the same computer by configuring them to use different ports.

Attempting to run a second instance of FairCom with the same port as a running instance will cause the second instance to exit with errors.

 
  1. Manage any running instances of FairCom in Windows Task Manager.