一、右擊桌面的個人電腦 -> 高級 -> 環境變量,新建
1) 變量名:ORACLE_HOME
變量值:D:\app\instantclient_11_2
2) 變量名:TNS_ADMIN
變量值:SIMPLIFIED CHINESE_CHINA.ZHS16GBK
3) 變量名:NLS_LANG
變量值:SIMPLIFIED CHINESE_CHINA.ZHS16GBK
4) 修改Path變量,在最後面添加D:\app\instantclient_11_2 (打開path編輯,最後面加上;D:\app\instantclient_11_2,
「;」用來分隔和前面的字段)
二、在D:\app\instantclient_11_2 目錄下新建一個tnsnames.ora文件,添加內容以下
LISTENER_ZHQUAN =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.3)(PORT = 1522))數據庫
LISTENER_ORCL =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.3)(PORT = 1522))oracle
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.3)(PORT = 1522))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl.redhat)
)
)
ZHQUAN =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.3)(PORT = 1522))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = zhquan.redhat)
)
)
三、至此,oracle客戶端配置完畢,你能夠直接經過PL/SQL Developer這樣的客戶端軟件來鏈接數據庫app
http://pan.baidu.com/share/link?shareid=1528306866&uk=2484678268get
也能夠下載一個
Instant Client Package - SQL*Plus(第3步的頁面下載),解壓到D:\app\instantclient_11_2中,便可用 SQL*Plus登陸數據庫。it