Oracle Client Libraries

In order to connect to an Oracle database from your Virtual Private Server, you will need to use an Oracle Client. Follow the instructions below to install the Oracle Client on your server.

  1. To install the client software, SSH or Telnet to your server and run the following command, depending on your server O/S.

  2. Configure the Client libraries to connect to your Oracle database. This is done by creating a tnsnames.ora file in your TNS_ADMIN directory. On your Virtual Private Server, this will be the ~/usr/local/oracle/network/admin/ directory.

    Your tnsnames.ora file needs to contain specific information about connecting to your Oracle database. It's probable that your database server has instructions on creating your tnsnames.ora file. The following is an example of what your tnsnames.ora file might look like if your database server's domain was mydatabase.myhosteddb.net.

    mydatabase.myhosteddb.net=
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = 
            (PROTOCOL = TCP) 
            (HOST = mydatabase.myhosteddb.net)
            (PORT = 1521)
          )
        )
        (CONNECT_DATA =
          (SERVICE_NAME = odb)
        )
      )

    If you create this file on your local computer and use FTP to copy it to your Virtual Private Server, be sure to use the ASCII file format when copying the file.

  3. To access the libraries from the shell, set the ORACLE_HOME environment variable according to your shell (the default shell is csh)