LSNCTL NL-00051報錯分析

charsi發表於2010-11-28

有時候會遇到下面的這個錯誤
LSNRCTL> save_config
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
NL-00051: internal error code, arguments: [302], [1], [], [], [], [], []

原因為沒有listener.ora檔案導致.

出現問題的過程如下:
[oracle:/home/oracle#]lsnrctl

LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 16-4?? -2011 15:02:14

Copyright (c) 1991, 2005, Oracle. All rights reserved.

Welcome to LSNRCTL, type "help" for information.

LSNRCTL> start
Starting /opt/ora10g/product/10.2.0/db_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Log messages written to /opt/ora10g/product/10.2.0/db_1/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))

Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 16-4?? -2011 15:02:15
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Log File /opt/ora10g/product/10.2.0/db_1/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
The listener supports no services
The command completed successfully
LSNRCTL>
LSNRCTL>
LSNRCTL> change_password
Old password:
New password:
Reenter new password:
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
Password changed for LISTENER
The command completed successfully
LSNRCTL> save_config
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
NL-00051: internal error code, arguments: [302], [1], [], [], [], [], []
LSNRCTL>


對於這類問題的解決方法:
如果能夠使用圖形化介面登陸的話,可以使用netca來建立listener.ora檔案.
如果不能使用圖形化介面,直接在$ORACLE_HOME/network/admin目錄下建立一個listener.ora檔案,即使是一個空的檔案也可以.

另外在Windows上測試的時候,不能修改Oracle listener的密碼,只能首先將listener.ora檔案中的密碼部分註釋掉,然後建立新的密碼才可.

[@more@]

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/23850820/viewspace-1048854/,如需轉載,請註明出處,否則將追究法律責任。

相關文章