[20230404]ORA-00132错误解决.txt

来源:这里教程网 时间:2026-03-03 18:37:32 作者:

[20230404]ORA-00132错误解决.txt --//在自己的测试环境模拟看看. 1.环境: SCOTT@book> @ ver1 PORT_STRING                    VERSION        BANNER ------------------------------ -------------- -------------------------------------------------------------------------------- x86_64/Linux 2.4.xx            11.2.0.4.0     Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production SCOTT@book> show parameter local_listener PARAMETER_NAME TYPE    VALUE -------------- ------- ----------------- local_listener string alter system set local_listener=LISTENER_ORCL scope=spfile; 2.问题再现: --//重启数据库略. SYS@book> startup ORA-00119: invalid specification for system parameter LOCAL_LISTENER ORA-00132: syntax error or unresolved network name 'LISTENER_ORCL' --//重启在alter.log记录如下: USER (ospid: 27301): terminating the instance due to error 119 Instance terminated by USER, pid = 2730 SYS@book> select open_mode from v$database ; select open_mode from v$database * ERROR at line 1: ORA-01034: ORACLE not available Process ID: 0 Session ID: 358 Serial number: 3 --//数据库根本没有起来. $ lsnrctl status LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 13-APR-2023 09:13:27 Copyright (c) 1991, 2013, Oracle.  All rights reserved. Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=0.0.0.0)(PORT=1521))) STATUS of the LISTENER ------------------------ Alias                     LISTENER Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production Start Date                27-MAR-2023 10:07:45 Uptime                    16 days 23 hr. 5 min. 42 sec Trace Level               off Security                  ON: Local OS Authentication SNMP                      OFF Listener Parameter File   /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora Listener Log File         /u01/app/oracle/product/11.2.0.4/dbhome_1/network/log/listener.log Listening Endpoints Summary...   (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))   (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) Services Summary... Service "Book" has 1 instance(s).   Instance "book", status UNKNOWN, has 1 handler(s) for this service... The command completed successfully --//仅仅启动静态服务. $ tnsping LISTENER_ORCL TNS Ping Utility for Linux: Version 11.2.0.4.0 - Production on 13-APR-2023 09:13:54 Copyright (c) 1997, 2013, Oracle.  All rights reserved. Used parameter files: /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/sqlnet.ora TNS-03505: Failed to resolve name --//修改tnsnames.ora文件加入如下: LISTENER_ORCL =  (ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1521)) $ tnsping LISTENER_ORCL TNS Ping Utility for Linux: Version 11.2.0.4.0 - Production on 13-APR-2023 09:14:35 Copyright (c) 1997, 2013, Oracle.  All rights reserved. Used parameter files: /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/sqlnet.ora Used TNSNAMES adapter to resolve the alias Attempting to contact (ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1521)) OK (0 msec) --// 再次启动: SYS@book> startup ORACLE instance started. Total System Global Area  643084288 bytes Fixed Size                  2255872 bytes Variable Size             205521920 bytes Database Buffers          427819008 bytes Redo Buffers                7487488 bytes Database mounted. Database opened. SYS@book> alter system register; System altered. $ lsnrctl status LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 13-APR-2023 09:15:34 Copyright (c) 1991, 2013, Oracle.  All rights reserved. Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=0.0.0.0)(PORT=1521))) STATUS of the LISTENER ------------------------ Alias                     LISTENER Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production Start Date                27-MAR-2023 10:07:45 Uptime                    16 days 23 hr. 7 min. 48 sec Trace Level               off Security                  ON: Local OS Authentication SNMP                      OFF Listener Parameter File   /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora Listener Log File         /u01/app/oracle/product/11.2.0.4/dbhome_1/network/log/listener.log Listening Endpoints Summary...   (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))   (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) Services Summary... Service "Book" has 2 instance(s).   Instance "book", status UNKNOWN, has 1 handler(s) for this service...   Instance "book", status READY, has 1 handler(s) for this service... Service "bookXDB" has 1 instance(s).   Instance "book", status READY, has 1 handler(s) for this service... The command completed successfully --//OK!! 3.收尾: SYS@book> alter system reset local_listener; System altered. --//重启不存在问题ok.

相关推荐