Configuring SequeLink® Server for ODBC Socket

Many of the SequeLink service templates provide a configuration that can be used without any modification. During installation of the SequeLink Server for ODBC Socket, you specify a service, a backend driver, and data source. The following sections describe how to add other services and data sources.

This information applies to Windows 200x, and Windows XP.

Configuring a SequeLink® Service for ODBC Socket on Windows

You can use the same SequeLink Server for ODBC Socket to connect with different ODBC drivers. For each ODBC driver you want to access, create a new ODBC system data source. In the server data sources of the SequeLink service, you can then specify a different DataSourceSOCODBCConnStr service attribute (see "DataSourceSOCODBCConnStr").

Setting Up the ODBC Driver Environment

Before setting up the SequeLink Server for ODBC Socket environment, ensure you have set up the backend ODBC driver environment and that you can make a connection to this ODBC driver.

Verifying the ODBC Driver Environment

The ivcheckodbc utility, which is installed in install_dir\tools\ivcheckodbc.bat, is used to test the backend ODBC driver.

To verify the environment for the backend ODBC driver:

  1. Create a system data source for your ODBC driver. Refer to your ODBC driver documentation for instructions on creating and testing a system data source.
  2. To make sure that you have set up the environment for the ODBC driver that you want to use, run the ivcheckodbc utility from a DOS prompt. For example:
  3. run ivcheckodbc.bat

    The ivcheckodbc utility makes a connection, checks the requirements of the backend ODBC driver, and returns the information you need to enter during the configuration of the SequeLink Server for ODBC Socket on Windows.

Configuring the SequeLink® Server for ODBC Socket

You can use the administrative tool of your choice to configure the SequeLink Server for ODBC Socket. The following procedure uses the MMC.

  1. Refer to the documentation for the ODBC driver that you want to access to determine whether it is a Unicode driver. Create the appropriate SequeLink service for the ODBC driver that you will be using.
    • For a non-Unicode driver, use SequeLink ODBC Socket Service.
    • For a Unicode driver, select SequeLink ODBC Socket Service (enhanced code page support).
  2. Right-click on SequeLink Services to create a new service, using the service template that you identified in Step 2.
  3. Enter the service name and the TCP/IP port. Then, click Next.
  4. Register the SequeLink Service and click Finish.
  5. Select the newly created SequeLink ODBC Socket Service.
  6. Select the data source you want to change, or create a new server data source by right-clicking Data Source Settings.
  7. Right-click the Advanced node, and select New / Attribute. The Properties window appears.
  8. From the drop-down list, select DataSourceSOCODBCConnStr.
  9. In the Value field, type the connect string of the data source you created in "Verifying the ODBC Driver Environment". For example, if you want the Socket Server to use the Oracle9i_on_host data source, type in the string DSN=Oracle9i_on_host.
  10. NOTE: This attribute contains the name of the ODBC system data source.

  11. Click OK. The attribute is changed.
  12. Save the configuration.

This information applies to Windows and UNIX.

Configuring a SequeLink® Service for ODBC Socket on Linux/UNIX

Before setting up the SequeLink Server for ODBC Socket environment:

The configuration examples are for a 32-bit environment. The examples are also valid for SequeLink Server for ODBC Socket in a 64-bit environment.

Setting Up the ODBC Driver Environment

Before setting up the SequeLink Server for ODBC Socket environment, ensure you have set up the backend ODBC driver environment and that you can make a connection to this ODBC driver.

Verifying the ODBC Driver Environment

The SequeLink Server for ODBC Socket uses the DataDirect ODBC Driver Manager. This driver manager loads the backend driver upon request, finding all of the necessary information in the backend ODBC data source configuration file odbc.ini, located in installdir/bin/odbc.

The odbc.ini file must contain one line in the [ODBC Data Sources] section and one section for the data source:

The ivcheckodbc utility, located in the install_dir/tools subdirectory, is used to test the backend ODBC driver with the DataDirect Driver Manager on Linux/UNIX. The DataDirect Driver Manager on Linux/UNIX is a requirement for SequeLink Server for ODBC Socket. For more information about the ivcheckodbc utility, refer to the SequeLink Troubleshooting Guide and Reference.

To verify the environment for the backend ODBC driver:

  1. Create a data source for your backend ODBC driver in the DataDirect Driver Manager configuration file, odbc.ini. Update the file to reflect the appropriate data source configuration information, based on the documentation of your backend driver.
  2. The following example uses the definitions for the DataDirect Progress ODBC driver.

    • In the [ODBC Data Source] section, add:
    • [ODBC Data Sources]

      dsn_prog_10=DataDirect 5.3 Progress10

      This entry identifies a new data source called dsn_prog_10 that uses the DataDirect 5.3 Progress10 ODBC driver. The Progress10 ODBC driver finds all the necessary configuration information in section [dsn_prog_10] of the odbc.ini file.

    • Add a [dsn_prog_10] section, as shown in this example on Solaris:
    • [dsn_prog_10]

      Driver=/usr/DataDirect/ODBC/0530/lib/ivpro1020.so

      Description=DataDirect 5.3 Progress OpenEdge

      DatabaseName=your_db

      HostName=your_host

      LogonID=your_uid

      password=your_pwd

      PortNumber=your_server_port

      This entry indicates that a Progress10 data source called dsn_prog_10 has been created. The ODBC driver for this datasource is located in the directory /usr/DataDirect/ODBC/0530/lib/.

  3. To make sure that you have set up the environment for the ODBC driver that you want to use, run the ivcheckodbc utility, for example:
  4. $ /usr/slserver60/tools/ivcheckodbc.sh

    The ivcheckodbc utility makes a connection, checks the requirements of the backend ODBC driver, and returns the information you need to enter during the configuration of the SequeLink Server for ODBC Socket on Linux/UNIX.

Configuring the SequeLink® Server for ODBC Socket

  1. Refer to the documentation for the ODBC driver that you want to access to determine whether it is a Unicode driver. Create the appropriate SequeLink service for the ODBC driver that you will be using.
    • For a non-Unicode driver, use SequeLink ODBC Socket Service.
    • For a Unicode driver in UTF-8 encoding, select SequeLink ODBC Socket Service (enhanced code page support for UTF8 drivers).
    • For a Unicode driver in UTF-16 encoding, select SequeLink ODBC Socket Service (enhanced code page support for UTF16 drivers).
  2. Use the administration tool of your choice to create a new service. This example uses the MMC. Right-click on SequeLink Services to create a new service, using the service template that you identified in "Verifying the ODBC Driver Environment".
    1. When prompted, perform the following actions:
      • In the Service Name field, type the service name you want to use for the new SequeLink service. The service name must be unique (not used by another service).
      • In the TCP port field, type the number of the TCP/IP port on which the new SequeLink service will be listening. The port must be an available port.
      • Click Next.
    2. The wizard prompts you to register the SequeLink service on the host machine. The default is to register the service, which makes the service information available to the operating system.
    3. Click Finish to create the new SequeLink service.
  3. The Driver Manager finds its configuration file using the environment variable ODBCINI. This environment variable is automatically set for the SequeLink Server for ODBC Socket environment. If you want to put the odbc.ini file elsewhere, modify the ODBCINI environment variable.
  4. See "ServiceEnvironmentVariable" for more information.

    ServiceEnvironmentVariable:

    ODBCINI=installdir/bin/odbc/odbc.ini

    1. Select the ODBC Socket Service that you created in Step 2.
    2. Select the Configuration node.
    3. Select the Service Settings node.
    4. Right-click the Environment node and select New/Attribute.
    5. Enter the setting for the environment variable. For example, on Solaris, enter:
    6. ServiceEnvironmentVariable: ODBCINI=newdir/odbc.ini

  5. Specify where the SequeLink Server for ODBC Socket can find the shared library of the driver manager and the backend ODBC driver (LIBPATH for AIX, SHLIB_PATH, for HP-UX, or LD_LIBRARY_PATH for Solaris and Linux).
    1. Select the ODBC Socket Service that you created in Step 2.
    2. Select the Configuration node.
    3. Select the Service Settings node.
    4. Right-click the Environment node and select New/Attribute.
    5. Enter the setting for the environment variable. For example, on Solaris, enter:
    6. ServiceEnvironmentVariable:LD_LIBRARY_PATH=/usr/DataDirect/ODBC/0530/lib/ivpro1020.so

  6. If the ODBC driver that you are using has required specific environment variables, add them as service attributes to the SequeLink Server for ODBC Socket configuration.
    1. Select the ODBC Socket Service that you created in Step 2.
    2. Select the Configuration node.
    3. Select the Service Settings node.
    4. Right-click the Environment node and select New/Attribute.
    5. Enter the setting for the environment variable and its value. For example, on Solaris,
    6. ServiceEnvironmentVariable: ORACLE_HOME=/db/oracle10

  7. Set the connection string the SequeLink Server for ODBC Socket service will use to connect:
    1. Select Data Source Settings; then select a node.
    2. Right-click the Advanced node and select New / Attribute. The Properties window appears.
    3. From the drop-down list, select DataSourceSOCODBCConnStr.
    4. In the Value field, type the connect string of the data source you want SequeLink Server for ODBC Socket to use. For example, if you want SequeLink Server for ODBC Socket to use the data source that you created in "Verifying the ODBC Driver Environment", type in the string DSN=dsn_prog_10.
  8. Click OK. The attribute is changed.
  9. Save the configuration.