Install Oracle client under Linux __ios

Source: Internet
Author: User

Download the installation package from the following website and choose your own version

Http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html

Download the client and Sqlplus programs from the Oracle official website.

Take 11g as an example

Install as root user
RPM-IVH oracle-instantclient-basic-11.1.0.1-1.x86_64.rpm
RPM-IVH oracle-instantclient-sqlplus-11.1.0.1-1.x86_64.rpm

You can use RPM-QPL oracle-instantclient-sqlplus-11.1.0.1-1.x86_64.rpm to view the installation path when you are finished installing

Default in/usr/lib/oracle directory
Configuration
Vim/etc/profile add
Export Oracle_home=/usr/lib/oracle/11.1.0.1/client64
Export oracle_base=/usr/lib/oracle/11.1.0.1
Export ld_library_path= $ORACLE _home/lib: $LD _library_path
Export Nls_lang=american_america. Al32utf8

Setting the environment variable requires rebooting the machine or source/etc/profile the configuration to take effect.

Creating a configuration file

Create the following directory Network/admin under the Oracle_home directory and create the file Tnsnames.ora as follows:


Vim/usr/lib/oracle/11.1.0.1/client64/network/admin/tnsnames.ora

ORCL = (DESCRIPTION = (Address_list = (address = (PROTOCOL = TCP) (host = host) (PORT = 1521)) (Connec T_data = (service_name = ORCL)))

Test

To the Oracle_home/bin directory, execute the command:

[Yleesun@centos bin]$./sqlplus zxd/zxd@111

Sql*plus:release 11.2.0.3.0 Production on Mon June 9 19:14:25 2012

Copyright (c) 1982, Oracle. All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition release 11.2.0.1.0-64bit Production
With the partitioning, OLAP, Data Mining and real application testing options

Sql>

The test was successful.

Note:

If the following error occurs:

Sqlplus:error while loading shared libraries:libsqlplus.so:cannot open Shared object file:no such file or directory
Indicates that the environment variable is not in effect or that the package needs to be installed

Yum install libaio* is done.


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.