2014年7月4日 星期五

Fix ORA-12528: TNS:listener: all appropriate instances are blocking new connections



1. login sqlplus
$  sqlplus username/password@dbname
SQL*Plus: Release 11.2.0.2.0 Production on Fri Jul 4 10:53:32 2014
Copyright (c) 1982, 2010, Oracle.  All rights reserved.
ERROR:
ORA-12528: TNS:listener: all appropriate instances are blocking new connections

2.  checking listener status: was BLOCKED
$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 04-JUL-2014 10:55:42
Copyright (c) 1991, 2010, Oracle.  All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=amosVirtualBox)(PORT=1521))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.2.0 - Production
Start Date                04-JUL-2014 10:51:39
Uptime                    0 days 0 hr. 4 min. 3 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /opt/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /opt/oracle/diag/tnslsnr/amosVirtualBox/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=amosVirtualBox)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=amos)))
Services Summary...
Service "ORCL.osp-dd.de" has 1 instance(s).
  Instance "ORCL", status BLOCKED, has 1 handler(s) for this service...
The command completed successfully



3. try to re-start database (but it doesn't work)
$ sqlplus
SQL*Plus: Release 11.2.0.2.0 Production on Fri Jul 4 10:55:55 2014
Copyright (c) 1982, 2010, Oracle.  All rights reserved.
Enter user-name: sys as sysdba
Enter password:
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning and OLAP options
SQL> shutdown immediate;

ORA-01507: database not mounted
ORACLE instance shut down.
SQL> SP2-0223: No lines in SQL buffer.
SQL> startup mount;
ORACLE instance started.
Total System Global Area 2087780352 bytes
Fixed Size    2228072 bytes
Variable Size 1174405272 bytes
Database Buffers  905969664 bytes
Redo Buffers    5177344 bytes
ORA-00214: control file '/home/amos/oradata/control01.ctl' version 165087
inconsistent with file '/opt/oracle/flash_recovery_area/ORCL/control02.ctl'
version 152932
SQL> SP2-0223: No lines in SQL buffer.

4. try to copy control01.ctl to control02.ctl
SQL> ! cp /home/amos/oradata/control01.ctl /opt/oracle/flash_recovery_area/ORCL/control02.ctl
SQL> ! cp /home/amos/oradata/control01.ctl /opt/oracle/flash_recovery_area/ORCL/control03.ctl

5. mount database
SQL> alter database mount;
Database altered.

6 open database 
SQL> alter database open;
Database altered.

7.  login sqlplus again, 
$sqlplus username/password@dbname
SQL*Plus: Release 11.2.0.2.0 Production on Fri Jul 4 11:22:11 2014
Copyright (c) 1982, 2010, Oracle.  All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning and OLAP options
SQL> 



沒有留言:

張貼留言