Startup and Shutdown Procedure

DATABASE STARTING PROCEDURE:

NOMOUNT:

You can start an instance without mounting a database. Typically, you can do so only during database creation.

Command: SQL>STARTUP NOMOUNT;

In NOMOUNT state the following things happen:

  1. Allocating SGA

  2. Starting the Background Processes

  3. Open trace file and alert log file

MOUNT:

You can start an instance and mount a database without opening it, allowing you to perform specific maintenance operations. For example, the database must be mounted but not open during the following tasks:

  • Enabling and disabling redo log-archiving options.

  • Performing full database recovery.

  • Renaming data file, redo file

Command: SQL>STARTUP MOUNT;

OPEN:

Normal database operation means that an instance is started and the database is mounted and open. This mode allows any valid user to connect to the database and perform typical data access operations.

Command: SQL>STARTUP;

Alter Database Command from One state to another State:

Change From NOMOUNT to MOUNT State:

SQL>ALTER DATEBASE MOUNT;

Change From MOUNT/NOMOUNT to OPEN State

SQL>ALTER DABASE OPEN;

RESTART DATABASE:

In unusual circumstances, you might experience problems when attempting to start a database instance. You should not force a database to start unless you are faced with the following:

  • You cannot shut down the current instance with the SHUTDOWN NORMAL, SHUTDOWN IMMEDIATE, or SHUTDOWN TRANSACTIONAL commands.

  • You experience problems when starting an instance.

Command: STARTUP FORCE;

STARTUP RESTRICT

You can start an instance, and optionally mount and open a database, in restricted mode so that the instance is available only to administrative personnel (not general database users). Use this mode of instance startup when you need to accomplish one of the following tasks:

· Perform an export or import of database data

· Perform a data load (with SQL*Loader)

· Temporarily prevent typical users from using data

· During certain migration and upgrade operations.

Typically, all users with the CREATE SESSION system privilege can connect to an open database. Opening a database in restricted mode allows database access only to users with both the CREATE SESSION and RESTRICTED SESSION system privilege. Only database administrators should have the RESTRICTED SESSION system privilege. Further, when the instance is in restricted mode, a database administrator cannot access the instance remotely through an Oracle Net listener, but can only access the instance locally from the machine that the instance is running on.

Command: SQL>STARTUP RESTRICT;

Or SQL>ALTER SYSTEM ENTABLE RESTRICTED SESSION;

To Disable Resticted Session Use the Following Command:

SQL>ALTER SYSTEM DISABLE RESTRICTED SESSION;

OPEN DATABASE IN READ ONLY MODE:

That will prevent any modification in Database:

Command: SQL> ALTER DATABASE OPEN READ ONLY;

DATABSE SHUTTING DOWN CONDITIONS:

Shutdown Normal | Transactional | Immediate | Abort

An aborted database shutdown proceeds with the following conditions:

· After issuing the statement, no new connection or transaction are allowed.

· Current client SQL statements being processed by Oracle Database are immediately terminated.

· Uncommitted transactions are not roll back.

· Oracle Database does not wait for users currently connected to the database to disconnect. The database implicitly disconnects all connected users.