Installing the Relay Server Components to Apache on Linux

After installing Sybase Unwired Platform, extract the relay server component files to the Apache install modules directory, edit the main configuration file for the Apache HTTP server, and set the environment variables.

  1. Copy relayserver_linux_x86.tar.gz from /modules/relayserver on the installation media to the host machine.
  2. Extract the contents to the Apache install modules directory.
    The file contains:
    • mod_rs_ap_client.so
    • mod_rs_ap_server.so
    • rshost
    • dblgen11.res
    • libdbtasks11_r.so
    • libdbicudt11.so
    • libdbicu11_r.so
    • libdblib11_r.so
    • dbsupport
  3. Create the relay server configuration file, rs.config.
  4. Copy rs.config into the modules directory.

    The server module expects the rshost executable to be in the same directory where you copied the rs.config file.

  5. Set the PATH and LD_LIBRARY_PATH environment variables to include the Apache modules directory.
  6. Edit the Apache conf/httpd.conf file.
    1. Add the following lines to load the Relay Server client and server modules.
      LoadModule iarelayserver_client_module modules/mod_rs_ap_client.so
      LoadModule iarelayserver_server_module modules/mod_rs_ap_server.so

      The client and server modules are invoked using different URLs. The client module explicitly looks for the string iarelayserver in the URL path.

    2. Add the following line to create a <location> section for the client module.
      <LocationMatch /cli/iarelayserver/* >
           SetHandler iarelayserver-client-handler
      </LocationMatch>
    3. Add the following line to create a <location> section for the server module.
      <Location /srv/iarelayserver/* >
           SetHandler iarelayserver-server-handler
           RSConfigFile "/<apache-install>/modules/rs.config"
      </Location>

      The RSConfigFile directive specifies the location of the relay server configuration file, rs.config. The rs.config file must reside in the same directory where the rshost executable is deployed.

  7. Determine if the following environment variables are set globally when Apache spawns a process: $TMP, $TMPDIR or $TEMP.

    Make sure the Apache user process has write permissions to the tmp directory location.

    • If the environmental variables are set globally, you are finished.
    • If these variables are not set globally, or you want the default relay server log file to go in a specific temporary directory, edit the /<apache-dir>/bin/envvars file to set and then export TMP.
      set TMP="/tmp"
      export TMP

      This command sets the environment variable in the shell that Apache creates before it spawns its processes.

Next 
Related tasks
Installing the Relay Server Components to IIS on Windows
Configuring a Relay Server for Production


Created September 17, 2009. Send feedback on this help topic to Sybase Technical Publications: pubs@sybase.com