1,mkdir-p/opt/oracle
2,cd/opt/oracle
3, to the Oracle official website Download the following three compressed package (preferably download and Orcale server corresponding version)
and upload it to the/opt/oracle directory.
Oracle-instantclient11.2-basic-11.2.0.1.0-1.x86_64.zip
Oracle-instantclient11.2-sqlplus-11.2.0.1.0-1.x86_64.zip
Oracle-instantclient11.2-sdk-11.2.0.1.0-1.x86_64.zip
The official address is as follows:
Http://www.oracle.com/technetwork/topics/linuxsoft-082809.html (32-bit)
Http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html (64-bit)
The download requires an Oracle account, not a free registration.
4.Copy and paste the following to install.sh
#!/bin/bash
#author Loopeelee
Yum Install-y libaio*
#不装这个包, the error will be as follows when connecting:
#/opt/oracle/lib/sqlplus:error while loading shared libraries:libaio.so.1:cannot open Shared object file:no such file or directory
Cd/opt/oracle
Unzip Oracle-instantclient11.2-basic-11.2.0.1.0-1.x86_64.zip >/dev/null 2>&1
Unzip Oracle-instantclient11.2-sqlplus-11.2.0.1.0-1.x86_64.zip >/dev/null 2>&1
MV Instantclient_11_2/lib
Unzip Oracle-instantclient11.2-sdk-11.2.0.1.0-1.x86_64.zip >/dev/null 2>&1
MV INSTANTCLIENT_11_2/SDK
Mkdir-p/opt/oracle/network/admin
Cd/opt/oracle/network/admin
#下面的HOST = and service_name = need to be modified according to their own values
echo ' wcsracdb =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.22.8) (PORT = 1521))
(Connect_data =
(SERVER = dedicated)
(service_name = Uerdb)
)
)
Extproc_connection_data =
(DESCRIPTION =
(Address_list =
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1))
)
(Connect_data =
(SID = Plsextproc)
(PRESENTATION = RO)
)
) ' > Tnsnames.ora
Echo ' Export oracle_home=/opt/oracle
Export Ld_library_path=/opt/oracle/lib ' >>/etc/profile
Source/etc/profile
5.chmod u+x install.sh
6. ./install.sh
7. Test:
/opt/oracle/lib/sqlplus
can also be so/opt/oracle/lib/sqlplus User/[email protected]
This article is from the "Chatter" blog, please be sure to keep this source http://loopeelee.blog.51cto.com/9835110/1603663
Linux FREE Installation Oracle client software connection Oracle database