install oracle client in slackware

21 Feb

oracle client slackware
1. download instantclient

http://www.oracle.com/technetwork/topics/linuxsoft-082809.html

a. instantclient-basiclite-linux32-11.2.0.2.0.zip
b. instantclient-sdk-linux32-11.2.0.2.0.zip
c. instantclient-sqlplus-linux32-11.2.0.2.0.zip

2. unzip instantclient
root@hl38:~# mkdir /u02
root@hl38:~# unzip instantclient-basiclite-linux32-11.2.0.2.0.zip -d /u02
root@hl38:~# unzip instantclient-sdk-linux32-11.2.0.2.0.zip -d /u02
root@hl38:~# unzip instantclient-sqlplus-linux32-11.2.0.2.0.zip -d /u02

3. konfigurasi /etc/ld.so.conf
root@hl38:~# echo /u02/instantclient_11_2/ >> /etc/ld.so.conf
root@hl38:~# cat /etc/ld.so.conf
/usr/local/lib
/usr/i486-slackware-linux/lib
/u02/instantclient_11_2/

4. konfigurasi /etc/profile
root@hl38:~# echo export ORACLE_HOME=/u02/instantclient_11_2 >> /etc/profile
root@hl38:~# echo export TNS_ADMIN=/u02/oracle >> /etc/profile
root@hl38:~# echo export SQLPATH=$ORACLE_HOME >> /etc/profile
root@hl38:~# echo export LD_LIBRARY_PATH=$ORACLE_HOME:$LD_LIBRARY_PATH >> /etc/profile
root@hl38:~# echo export PATH=$PATH:$SQLPATH >> /etc/profile

5. konfigurasii sqlnet.ora & tnsnames.ora
root@hl38:~# mkdir /u02/oracle

ubs@hl38:~$ vi /u02/oracle/sqlnet.ora
# SQLNET.ORA Network Configuration File: /u01/app/oracle/product/8.1.7/network/admin/sqlnet.ora
# Generated by Oracle configuration tools.
NAMES.DIRECTORY_PATH= (TNSNAMES, ONAMES, HOSTNAME)

ubs@hl38:~$ cat /u02/oracle/tnsnames.ora
orcl9 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 172.20.141.25)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl9)
(INSTANCE_NAME = orcl9)
)
)

6. test sqlplus
ubs@hl38:~$ /u02/instantclient_11_2/sqlplus
SQL*Plus: Release 11.2.0.2.0 Production on Mon Feb 21 12:58:09 2011
Copyright (c) 1982, 2010, Oracle.  All rights reserved.
Enter user-name: scott@orcl9
Enter password:
Connected to:
Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 – Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> select * from dept;
DEPTNO DNAME          LOC
———- ————– ————-
10 ACCOUNTING     NEW YORK
20 RESEARCH       DALLAS
30 SALES          CHICAGO
40 OPERATIONS     BOSTON

SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 – Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

About these ads

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: