To enable Oracle to the nomount state on Windows, enter the following command without starting the oracle service:
- C: \> sqlplus/nolog
- SQL * Plus: Release 10.2.0.1.0-Production on Friday October 14 16:28:13 2011
- Copyright (c) 1982,200 5, Oracle. All rights reserved.
- SQL> connect/as sysdba
- ERROR:
- ORA-12560: TNS: protocol adapter error.
- SQL>
Start the listening service (command: lsnrctl start can also start the service, and can display the IP address and Port number of the listener ):
Net start oracleoradb10g_home1tnslistener
The listening service is started successfully. However, the same error still occurs when the connect command is entered again in sqlplus.
I found this problem on the Internet and found that many people have encountered it. If you have encountered a similar problem, try the following methods:
1. In Windows, when we start the Database Service, the database automatically enters the Open state. To start now to the nomount status, you must modify the registry and set the key value to HKEY_LOCAL_MACHINE \ SOFTWARE \ ORACLE \ KEY_OraDb10g_home1.The value of ORA_ORCL_AUTOSTART is changed to FALSE. After modification, it will not automatically start to the Open state, so that it will have the opportunity to start to the nomount state.
The following will first start the service and then connect.
- C: \> net start OracleServiceOrcl
- The OracleServiceORCL service is starting.
- The OracleServiceORCL service has been started successfully.
- C: \> sqlplus/nolog
- SQL * Plus: Release 10.2.0.1.0-Production on Friday October 14 17:08:14 2011
- Copyright (c) 1982,200 5, Oracle. All rights reserved.
- SQL> connect/as sysdba
- Already connected to the idle routine.
- SQL> startup nomount
- The ORACLE routine has been started.
- Total System Global Area 603979776 bytes
- Fixed Size 1250380 bytes
- Variable Size 213912500 bytes
- Database Buffers 381681664 bytes
- Redo Buffers 7135232 bytes
- SQL>
Next, you can modify the database to the mount and open statuses.
- SQL> alter database mount
- The database has been changed.
- SQL> alter database open;
- The database has been changed.
- SQL>
2. Directly start the Database Service, connect to the database, shut down, and then start to nomount.
Why? The main reason is as mentioned above. If oracle's startup parameters in the Registry are not modified, once the service is started, the database will be in the open state and it will not be transferred to the nomount state.
The memory process is still running, and oracle accounts for a small amount of memory, because the memory in the global zone of the SGA system has been released.
- C: \> sqlplus/nolog
- SQL * Plus: Release 10.2.0.1.0-Production on Friday October 14 17:24:59 2011
- Copyright (c) 1982,200 5, Oracle. All rights reserved.
- SQL> connect/as sysdba
- Already connected to the idle routine.
- SQL> startup nomount
- The ORACLE routine has been started.
- Total System Global Area 603979776 bytes
- Fixed Size 1250380 bytes
- Variable Size 218106804 bytes
- Database Buffers 377487360 bytes
- Redo Buffers 7135232 bytes
- SQL>
- SQL> alter database mount
- 2;
- The database has been changed.
- SQL> alter database open;
- The database has been changed.
- SQL>
In addition, when the database is closed and restarted to the open state, the order of closing the database is shown below (The database has been closed, the database has been detached, And the ORACLE routine has been closed.), The order of startup (The ORACLE routine has been started, the database has been loaded, and the database has been opened).
- SQL> shutdown immediate;
- The database has been closed.
- The database has been detached.
- The ORACLE routine has been disabled.
- SQL> startup open;
- The ORACLE routine has been started.
- Total System Global Area 603979776 bytes
- Fixed Size 1250380 bytes
- Variable Size 218106804 bytes
- Database Buffers 377487360 bytes
- Redo Buffers 7135232 bytes
- The database has been loaded.
- The database has been opened.
- SQL>
In addition, if the database is directly started to the nomount state, it cannot be started to the mount state (unless shutdown first). You can only modify the database status to the mount state through the alter database mount statement, similarly, the open state is the same, that is, it can only be:
First:
Startup nomount;
Alter database mount;
Alter database open;
Second:
Startup nomount;
Alter database open;
Third:
Startup open;
As shown below:
Startup nomount;
Startup mount;This will cause the ora_01081 error.