• Home
  • Databases
  • How to use the Oracle STARTUP command to start out an Oracle Database instance

How to use the Oracle STARTUP command to start out an Oracle Database instance

Last updated on May 31 2022
Sankalp Joshi

Table of Contents

How to use the Oracle STARTUP command to start out an Oracle Database instance

In this blog, you’ll find out how to use the Oracle STARTUP command to start out an Oracle Database instance.

To start up a database instance, you employ the STARTUP command:

STARTUP

When the Oracle Database starts an instance, it goes through the subsequent stages: NOMOUNT, MOUNT, and OPEN.

 

The STARTUP command allows you to regulate the stage of the database instance.

1) NOMOUNT stage

In the NOMOUNT stage, Oracle carries the subsequent steps:

  • First, look for a server parameter enter the default location. you’ll override the default behavior by using the SPFILE or PFILE parameters within the STARTUP command.
  • Next, read the parameter file to urge the values of the initialization parameters.
  • Then, allocate the system global area (SGA) supported the initialization parameter settings.
  • After that, start the Oracle background processes like SMON, PMON, and LGWR.
  • Finally, open the alert log and trace files and record all explicit parameters to the alert log within the valid parameter syntax.

At the NOMOUNT stage, Oracle doesn’t associate the database with the instance.

2) MOUNT stage

In the MOUNT stage, Oracle associates a database with an instance. In other words, the instance mounts the database.

The instance carries the subsequent steps to mount a database:

  • First, get the name of the database control files laid out in the CONTROL_FILE initialization parameter.
  • Second, open the control files.
  • Third, find the name of knowledge files and therefore the online redo log files.

When a database is mounted, the database is merely available to database administrators, not all users.

3) OPEN stage

In the OPEN stage, Oracle performs the subsequent actions:

  • First, open the web data files in tablespaces aside from the undo tablespaces.
  • Then, select an undo tablespace. The instance uses default undo tablespace if an undo tablespace is laid out in the UNDO_TABLESPACE initialization parameter. Otherwise, it’ll select the primary available undo tablespace.
  • Finally, open the web redo log files.

When Oracle opens a mounted database, the database is out there for normal operations.

The following picture illustrates the Oracle database startup process:

 

Oracle STARTUP command

The basic syntax of the STARTUP command is as follows:

STARTUP;

It is like start the database instance within the OPEN stage:

STARTUP OPEN;

If you would like to start out the database instance during a specific stage, you’ll use the subsequent syntax:

 

STARTUP stage;

For example, to start out up a database instance within the NOMOUNT stage, you employ the subsequent command:

STARTUP NOMOUNT;

To bring the database to subsequent stage, you employ the ALTER DATABASE statement. for instance , this statement brings the database from the NOMOUNT to the MOUNT stage:

ALTER DATABASE MOUNT;

Oracle STARTUP command example

First, launch the SQL*Plus program and log in to the Oracle Database because the SYS user.

Second, issue the SHUTDOWN IMMEDIATE command to pack up the database:

shutdown immediate;

Here is that the output:

Database closed.

Database dismounted.

ORACLE instance pack up .

Third, start the database instance at the OPEN stage:

startup

Here is that the output:

 

Fourth, pack up the instance again:

 

shutdown immediate;

Fifth, start the database instance at the MOUNT state:

 

startup mount;

The output is:

ORACLE instance started.

 

Total System Global Area 2550136832 bytes

Fixed Size 3835304 bytes

Variable Size 738200152 bytes

Database Buffers 1795162112 bytes

Redo Buffers 12939264 bytes

Sixth, check the present status of the database instance by querying the v$instance view:

 

SELECT

instance_name,

status

FROM

v$instance;

Output:

INSTANCE_NAME STATUS

—————- ————

orcl MOUNTED

Seventh, bring the database to the OPEN stage by using the ALTER DATABASE command:

ALTER DATABASE OPEN;

Output:

Database altered.

Finally, check the status of the database by executing the subsequent statement:

 

SELECT

instance_name,

status

FROM

v$instance;

Now, the database is open and available for normal operations.

 

INSTANCE_NAME STATUS

—————- ————

orcl OPEN

So, this brings us to the end of blog. This Tecklearn ‘How to use the Oracle STARTUP command to start an Oracle Database instance’ blog helps you with commonly asked questions if you are looking out for a job in Oracle DB. If you wish to learn Oracle DB and build a career in Database domain, then check out our interactive, Oracle 12c DBA Training, that comes with 24*7 support to guide you throughout your learning period. Please find the link for course details: https://www.tecklearn.com/course/oracle-12c-dba-course/

Oracle 12c DBA Course Training

About the Course

Oracle Database Administration training will help you master the Oracle DBA. As part of the training, you will master the Oracle Database architecture, the database processes, memory structures, schema objects, security, data recovery and backup through hands-on projects and case studies. Oracle DBA Training helps students gain the skills and knowledge required to install, configure, and administer Oracle databases. Besides, this training also develops the full skill set required to become a successful Oracle Database Administrator.

Why Should you take Oracle DBA Training?

  • The Average salary of an Oracle DBA is $108,837 per annum – GlassDoor.com
  • According to Gartner, Oracle is the market leader in the Relational Database with 48.35% market share globally.
  • IBM, TCS, Tech Mahindra, Oracle, Wipro & other MNCs worldwide use Pl-SQL for their database deployments.

What you will Learn in this Course?

Introduction to Oracle Database

  • What is the Oracle Database
  • Pre-requisites for oracle database
  • Oracle database 12c installation
  • Multi-tenant architecture

Exploring the Oracle 12c Database Architecture

  • Explain the Memory Structures
  • Describe the Process Structures
  • Overview of Storage Structures

Preparing the Database Environment

  • Identify the tools for Administering an Oracle Database
  • Plan an Oracle Database Installation
  • Install the Oracle Software by using Oracle Universal Installer (OUI)
  • Create a Database by using the Database Configuration Assistant (DBCA)

Managing the Oracle Instance

  • Setting database initialization parameters
  • Describe the stages of database startup and shutdown

Database Storage Structures and Schema Objects

  • Managing Database Storage Structures
  • Overview of table space and data files
  • Overview of Primary Components
  • Identify the importance of checkpoints, redo log files, and archived log files
  • Configure ARHIVELOG mode

Database Startup & User Requests and Oracle Network Environment

  • Describe the stages of database startup and shutdown
  • Using alert log and trace files
  • Configure and Manage the Oracle Network
  • pFile and spFile
  • Tablespace Management
  • Storage and Relationship Structure

Oracle Backup & Recovery

  • Redo log File Management
  • Performing Database Recovery
  • Overview of Data Recovery Advisor
  • Use Data Recovery Advisor to Perform recovery (Control file, Redo log file and Data file)

Deep Dive into Oracle Recovery Manager (RMAN)

  • Using the RMAN Recovery Catalog
  • Identify situations that require RMAN recovery catalog
  • Create and configure a recovery catalog
  • Synchronize the recovery catalog
  • Create and Use RMAN stored scripts
  • Back up the recovery catalog
  • Create and use a virtual private catalog

Configuring Backup Specifications

  • Using RMAN to Create Backups
  • Create image file backups
  • Create a whole database backup
  • Enable fast incremental backup
  • Using RMAN to Perform Recovery
  • Perform complete recovery from a critical or noncritical data file loss using RMAN
  • Perform incomplete recovery using RMAN

Data Movement and Oracle Data Pump

  • Moving Data
  • Describe and use methods to use move data (Directory objects, SQL* Loader, External tables)
  • Explain the general architecture of Oracle Data Pump

Data Dictionary & Dynamic Performance Tables

  • Oracle Data Dictionary contains information related to database privileges
  • Data dictionary views
  • Media failure
  • Flashback CDB

Database Tuning

  • What is database tuning
  • How to tune the database
  • Tuning the data dictionary

 

0 responses on "How to use the Oracle STARTUP command to start out an Oracle Database instance"

Leave a Message

Your email address will not be published. Required fields are marked *