Navicat连接oracle 11g

时间:2024-03-15 07:02:20

Navicat软件连接oracle需要oracle client。oracle安装在虚拟机redhat中。
1.下载Instant Client Downloads for Microsoft Windows (x64) 64-bit两个软件,并解压到PC。

 instantclient-basic-windows.x64-12.2.0.1.0.zip 
 instantclient-sqlplus-windows.x64-12.2.0.1.0.zip 
oracle官方链接:http://www.oracle.com/technetwork/topics/winx64soft-089540.html


2.安装navicat
navicat112_premium_en_x64.exe  链接:http://pan.baidu.com/s/1kVQACKJ 

3.配置 (用到第1步的软件)

navicat连接oracle时需要配置oci.dll。打开navicat–>tools–>options–>miscellaneous–>OCI,在右侧将oci library的值设置为oracle instant client basic目录下的oci.dll所在位置,SQL* Plus 值同上指定sqlplus.exe的位置。

Navicat连接oracle 11g

 4.服务器关闭防火墙
1)永久性生效,重启后不会复原 
 开启: chkconfig iptables on 
关闭: chkconfig iptables off 
2)即时生效,重启后复原 
开启: service iptables start 
关闭: service iptables stop 

 5.检查服务端listener.ora 

[email protected] admin]$ more listener.ora
# listener.ora Network Configuration File: /app/oracle_11/app/oracle/product/11.
2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.


LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
      (ADDRESS = (PROTOCOL = TCP)(HOST =
REDHAT )(PORT = 1521)) 如果是localhost需更改为主机名
    )
  )

若修改,需重启监听。
查看状态命令:lsnrctl status
启动监听:lsnrctl start
关闭监听:lsnrctl stop

6.测试后可以正常连接到oracle.