首页 > 其他 > 详细

lsnrctl status 缺少Listener Parameter File信息

时间:2014-04-16 13:18:32      阅读:796      评论:0      收藏:0      [点我收藏+]

一:环境信息

主机平台:linux 6.2

数据库版本:11.2.0.3(psu5)单实例

二:问题现象

  lsnrctl status查看监听状态时发现没有监听文件(Listener Parameter File,正常情况是会有监听文件信息的)

--注意因为问题库是商用库,不能把信息直接发出来。下面的内容是用测试环境模拟的

1.问题库的lsnrctl status信息

[oracle@localhost admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 15-APR-2014 17:47:28
Copyright (c) 1991, 2013, Oracle.  All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date                15-APR-2014 17:25:41
Uptime                    0 days 0 hr. 21 min. 47 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Log File         /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status READY, has 1 handler(s) for this service...
The command completed successfully

2. 正常库的lsnrctl status信息

[oracle@localhost admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 15-APR-2014 17:24:56
Copyright (c) 1991, 2013, Oracle.  All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost.localdomain)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date                15-APR-2014 17:17:16
Uptime                    0 days 0 hr. 7 min. 39 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0.4/db_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status READY, has 1 handler(s) for this service...
The command completed successfully

--注意对比发现1,2的信息发现问题库的lsnrctl status信息中缺少“Listener Parameter File *****”这一行信息。 cd $ORACLE_HOME/network/admin 下发现确实没有listener.ora文件。这个问题到底是怎么出现的呢?查了MOS也没找到什么相关的信息。

三:故障模拟1

----个人猜测可能是listener.ora文件被别人误删了,所以决定从这个方面着手模拟

1. lsnrctl status(某个正常库,“Listener Parameter File”信息存在)

[oracle@localhost admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 15-APR-2014 17:24:56
Copyright (c) 1991, 2013, Oracle.  All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost.localdomain)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date                15-APR-2014 17:17:16
Uptime                    0 days 0 hr. 7 min. 39 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/product/11.2.0.4/db_1/network/admin/listener.ora
Listener Log File         /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status READY, has 1 handler(s) for this service...
The command completed successfully

2. 删除listener.ora文件

cd $ORACLE_HOME/network/admin

mv listener.ora listener.ora.bak

3. lsnrctl status

--同第一步中lsnrctl status信息完全相同(删除以后信息还是正常的,可能是因为监听没有重启下面我们重启监听试试)

4.重启监听

1)lsnrctl stop

2)lsnrctl start

3)lsnrctl status

[oracle@localhost admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 15-APR-2014 17:47:28
Copyright (c) 1991, 2013, Oracle.  All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date                15-APR-2014 17:25:41
Uptime                    0 days 0 hr. 21 min. 47 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Log File         /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status READY, has 1 handler(s) for this service...
The command completed successfully

--问题现象重现,此时的监听信息中已没有了“Listener Parameter File”信息。

 

5.还原listener.ora文件

1)mv listener.ora.bak listener.ora

2)lsnrctl status(还是没有“Listener Parameter File”信息)

3)重启监听

lsnrctl stop

lsnrctl start

4)lsnrctl status(出现“Listener Parameter File”信息)

--监听恢复正常

本文出自 “技术” 博客,请务必保留此出处http://589985.blog.51cto.com/1609992/1395963

lsnrctl status 缺少Listener Parameter File信息,布布扣,bubuko.com

lsnrctl status 缺少Listener Parameter File信息

原文:http://589985.blog.51cto.com/1609992/1395963

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!