Configure the Oracle 11g client in RHEL/CentOS

Source: Internet
Author: User

Oracle 11g linux 32-bit client Configuration

First, attach your own integrated client download link: Oracle 11g client Linux-32bit

Download from FTP No. 1 of the customer's home:

------------------------------------------ Split line ------------------------------------------

FTP address: ftp://ftp1.bkjia.com

Username: ftp1.bkjia.com

Password: www.bkjia.com

Configure the Oracle 11g client in LinuxIDC.com/2013 \ RHEL & CentOS

For the download method, see

------------------------------------------ Split line ------------------------------------------

Function:

1. including the basic operating environment of oracle;
2. includes the sqlplus component;
3. Including the sdk environment for oracle Application Development;
4. Contains pro * c development components;

Running environment:

CentOS 6.5 32-bit

1. download the following components:

1). instantclient-basic-linux-11.2.0.4.0.zip basic operation support database environment, OCI, OCCI, and JDBC-OCI operation of the basic environment;

2). instantclient-sdk-linux-11.2.0.4.0.zip contains some header files for oracle program development;

3). instantclient-precomp-linux-11.2.0.4.0.zip PRO * C program development used in the pre-compilation tool, that is, proc program;

4). instantclient-sqlplus-linux-11.2.0.4.0.zip SQL * PLUS Tool

2. Place the downloaded files in the same directory. For example, if I log on as a root user, put the above four zip files in the/root directory:

Decompress four files one by one:

[Root @ rhel ~] # Unzip instantclient-basic-linux-11.2.0.4.0.zip

[Root @ rhel ~] # Unzip instantclient-precomp-linux-11.2.0.4.0.zip

[Root @ rhel ~] # Unzip instantclient-sdk-linux-11.2.0.4.0.zip

[Root @ rhel ~] # Unzip instantclient-sqlplus-linux-11.2.0.4.0.zip

All the files in the last four zip files are stored in the instantclient_11_2 directory.

3. Go to the instantclient_11_2 directory and create the libclntsh. so.11.1 link file to prevent errors caused by the program failing to find the libclntsh. so file.

Run the following command in the instantclient_11_2 directory:

[Root @ rhel instantclient_11_2] # ln-s libclntsh. so.11.1 libclntsh. so

4. Create related directories:

Create a network directory under the instantclient_11_2 directory and create an admin directory under the network directory. The command is as follows:

[Root @ rhel instantclient_11_2] # mkdir-p network/admin

5. Configure Environment Variables

Use vi to open the user configuration file: vi ~ /. Bash_profile

Add the following information to the configuration file:

Export ORACLE_HOME =/root/instantclient_11_2

If ["$ LD_LIBRARY_PATH" = ""]; then
Export LD_LIBRARY_PATH = $ ORACLE_HOME
Else
Export LD_LIBRARY_PATH = $ LD_LIBRARY_PATH: $ ORACLE_HOME
Fi

Export PATH = $ PATH: $ ORACLE_HOME/sdk
Export NLS_LANG = "AMERICAN_AMERICA.AL32UTF8"
Export TNS_ADMIN = $ ORACLE_HOME/network/admin

If [-f "/usr/bin/rlwrap"]; then
Alias sqlplus = 'maid sqlplus'
Fi

Run the following command to make the environment variable take effect:

 

Source ~ /. Bash_profile

  • 1
  • 2
  • Next Page

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.