找到listener.ora文件:我的Oracle是安装在F盘,
路径为:F:\oracle\product\10.2.0\db_1\network\admin\listener.ora 修改前的配置如下:
# listener.ora Network Configuration File: F:\oracle\product\10.2.0\db_1\network\admin\listener.ora
# Generated by Oracle configuration tools.
SID_LIST_LISTENER =
(SID_LIST = (SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = F:\oracle\product\10.2.0\db_1)
(PROGRAM = extproc) ) )
LISTENER = (DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) ) )
修改后的配置如下:
# listener.ora Network Configuration File: F:\oracle\product\10.2.0\db_1\network\admin\listener.ora
# Generated by Oracle configuration tools.
SID_LIST_LISTENER = (SID_LIST =
(SID_DESC = (SID_NAME = PLSExtProc)
(ORACLE_HOME = F:\oracle\product\10.2.0\db_1)
(PROGRAM = extproc) )
(SID_DESC =
(GLOBAL_DBNAME = ORCL)
(ORACLE_HOME = F:\oracle\product\10.2.0\db_1)
(SID_NAME = ORCL) )
)
LISTENER = (DESCRIPTION_LIST =
(DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
(ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521)) ) )
红色部分为增加的内容 重启监听器