zoukankan      html  css  js  c++  java
  • Windows环境下修改Oracle实例监听IP地址

    Windows环境下修改Oracle实例监听IP地址。

    配置文件路径:<ORACLE_HOME>NETWORKADMIN

    如:C:Oracle11gR2product11.2.0dbhome_1NETWORKADMIN

    一、修改配置文件:listener.ora

    # listener.ora Network Configuration File: D:Oracle11gR2product11.2.0dbhome_1
    etworkadminlistener.ora
    # Generated by Oracle configuration tools.
    
    SID_LIST_LISTENER =
      (SID_LIST =
        (SID_DESC =
          (SID_NAME = CLRExtProc)
          (ORACLE_HOME = D:Oracle11gR2product11.2.0dbhome_1)
          (PROGRAM = extproc)
          (ENVS = "EXTPROC_DLLS=ONLY:D:Oracle11gR2product11.2.0dbhome_1inoraclr11.dll")
        )
        (SID_DESC =
          (SID_NAME = orcl)
          (ORACLE_HOME = D:Oracle11gR2product11.2.0dbhome_1)
        )
      )
    
    LISTENER =
      (DESCRIPTION_LIST =
        (DESCRIPTION =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
          (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.100)(PORT = 1521))
        )
      )
    
    ADR_BASE_LISTENER = D:Oracle11gR2

    修改listener.ora配置文件中LISTENER节点中host的地址由localhost为IP地址。

    另外,一定要在SID_LIST节点中添加一个SID_DESC节点说明。否则会在启动服务时会报如下错误提示。

    内网通截图20180808161916

    二、修改配置文件:tnsnames.ora

    修改tnsnames.ora配置文件中的地址为IP地址:

    # tnsnames.ora Network Configuration File: D:Oracle11gR2product11.2.0dbhome_1
    etworkadmin	nsnames.ora
    # Generated by Oracle configuration tools.
    
    LISTENER_ORCL =
      (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    
    
    ORACLR_CONNECTION_DATA =
      (DESCRIPTION =
        (ADDRESS_LIST =
          (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
        )
        (CONNECT_DATA =
          (SID = CLRExtProc)
          (PRESENTATION = RO)
        )
      )
    
    ORCL =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.100)(PORT = 1521))
        (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = orcl)
        )
      )

    通过以上的配置后,重启Oracle监听及实例服务后即可在其他计算机中通过IP地址连接。

  • 相关阅读:
    poj3984 迷宫问题(简单搜索+记录路径)
    substr
    poj3087 Shuffle'm Up
    学生管理系统
    win10配置gcc编译环境
    poj3278 Catch That Cow
    将字符串str1复制为字符串str2的三种解决方法
    poj2251 Dungeon Master
    cf 410
    7.20 Codeforces Beta Round #8
  • 原文地址:https://www.cnblogs.com/xusweeter/p/9459578.html
Copyright © 2011-2022 走看看