ITPub博客

首页 > 数据库 > Oracle > Oracle10g监听端口改变后 DB Control 不能用的解决方法

Oracle10g监听端口改变后 DB Control 不能用的解决方法

Oracle 作者:chzhh 时间:2010-12-04 13:47:23 0 删除 编辑

修改前的listener.ora (D:oracleproduct10.2.0db_1NETWORKADMINlistener.ora)

 

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = D:oracleproduct)
      (PROGRAM = extproc)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = logicgate)(PORT = 1521))
    )
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
    )
  )

 

修改后的listener.ora

 

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = D:oracleproduct)
      (PROGRAM = extproc)
    )
    (SID_DESC =
      (GLOBAL_DBNAME = epcit)
      (ORACLE_HOME = d:oracleproduct)
      (SID_NAME = epcit)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = logicgate)(PORT = 1523))
    )
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
    )
  )

 

监听端口从1521变为1523。由于oracle实例的动态注册只能在默认端口1521上运行,端口改变后我这里使用了静态注册。重新启动监听器:

 

D:>lsnrctl stop

D:>lsnrctl start

D:>lsnrctl services

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=logicgate)(PORT=1523)))
Services Summary...
Service "PLSExtProc" has 1 instance(s).
  Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0
         LOCAL SERVER
Service "epcit" has 1 instance(s).
  Instance "epcit", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0
         LOCAL SERVER
The command completed successfully

 

可以看到数据库实例"epcit"已经成功注册到监听器的端口1523上面。改变监听器端口后运行tnsping会出错,但只要更改tnsnames.ora中对应的端口就可以了。

 

然后登陆database control, 出现如下错误:Enterprise Manager is not able to connect to the database instance. The state of the components are listed below。修改方法如下:

 

1、%oracle_home\%hostname%_epcitsysmanconfigemoms.properties 在这个文件里我们可以找到两个和端口有关的设置

oracle.sysman.eml.mntr.emdRepPort=1521

oracle.sysman.eml.mntr.emdRepConnectDescriptor=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=LOGICGATE)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=epcit)))

把旧的端口改为新的端口就ok。

 

2、%oracle_home\%hostname%_epcitsysmanemd argets.xml  把所有旧的端口换成新的。

 

3、重启database control,登陆oem,成功!

<!-- 正文结束 -->

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/21969380/viewspace-1114823/,如需转载,请注明出处,否则将追究法律责任。

上一篇: 没有了~
下一篇: 没有了~
请登录后发表评论 登录
全部评论

注册时间:2009-06-24