Database Reference
In-Depth Information
Shutting Down the CDB
The DBA can shut down a database instance with SQL*Plus by connecting as a user with
SYSOPER, SYSDBA, SYSBACKUP, or SYSDG privileges and then issuing the SHUTDOWN
command. When the shutdown is complete, control is returned to the session that issued
the database SHUTDOWN command. If a user attempts to connect while a shutdown is in
progress, an error message similar to this will be returned:
SQL> connect c##cdbuser/common
ERROR:
ORA-01089: immediate shutdown or close in progress - no operations are permitted
Process ID: 0
Session ID: 0 Serial number: 0
SQL>
The valid modes to shut down a database are normal, transactional, immediate, and
abort. SHUTDOWN NORMAL waits for all users to disconnect. SHUTDOWN TRANSACTIONAL waits
for users to complete either by committing or rolling back pending transactions before
shutting down. SHUTDOWN IMMEDIATE rolls back any pending transactions prior to shutting
down. SHUTDOWN ABORT stops all processes immediately.
SHUTDOWN NORMAL CDB Instance
SHUTDOWN NORMAL is the default, so the NORMAL clause is optional. Issuing SHUTDOWN NORMAL
disallows new connections and waits for all current connections to disconnect from the
database. Just be aware that the database will not shut down until all users disconnect. If
you're in a hurry or need to run a scheduled task with the database down, then SHUTDOWN
NORMAL is probably not the right command option at this time:
SQL> shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
The next time you start up the database, it will not require instance recovery.
SHUTDOWN IMMEDIATE CDB Instance
For a DBA, SHUTDOWN IMMEDIATE is a very useful command that safely brings the database
down as quickly as possible. Use the IMMEDIATE option in the following situations:
When you need to start a cold backup
When server maintenance, a restart, or power down is required and the databases need
to be brought offline
When you need to restart the database because the database is functioning abnormally
Search WWH ::




Custom Search