0% found this document useful (0 votes)
44 views7 pages

Cracking Oracle DBA Interview

Uploaded by

mjamal.dba
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views7 pages

Cracking Oracle DBA Interview

Uploaded by

mjamal.dba
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Oracle DBA

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA

Oracle Database Architecture

Understanding Oracle Database Architecture: A Quick Overview

Oracle Database, developed by Oracle Corporation, is a widely adopted Relational Database


Management System (RDBMS). Known for its high performance, scalability, and reliability,
it powers a wide range of enterprise applications. Oracle supports various programming
languages and development tools, making it a flexible choice for developers and database
professionals.

Key Features Include:

• Support for data warehousing, transaction processing, and advanced analytics

• Built-in capabilities for high availability, disaster recovery, and strong security

Oracle follows a client-server architecture where:

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA
• The server manages data and system resources

• The client interacts with the server to query or update data


Common interaction tools include SQL, PL/SQL, and Java, along with management
tools like SQL*Plus and Oracle Enterprise Manager.

Core Components of Oracle Architecture:

Instance Components (Memory + Processes)


The Oracle instance is made up of two primary components:

1. SGA (System Global Area) – A shared memory region for managing data and control
information

2. Background Processes – Tasks like writing data to disk, monitoring other processes, and
system recovery

Important SGA Subcomponents:

• Database Buffer Cache – Caches frequently used data blocks


• Redo Log Buffer – Records all changes for recovery purposes

• Shared Pool – Stores SQL execution plans and parsed statements

• Large Pool & Java Pool – Optimizes memory for large operations and Java-related
activities

Key Background Processes:

• SMON (System Monitor) – Handles instance recovery

• PMON (Process Monitor) – Oversees failed user processes

• DBWR (Database Writer) – Writes modified data to disk

• LGWR (Log Writer) – Writes changes from the redo log buffer
• CKPT (Checkpoint) – Updates data/control files with the latest checkpoint info

Database System Storage


Oracle's storage is categorized into several file types:

• Data Files – Store the actual user data

• Redo Log Files – Track all changes for recovery


• Control Files – Maintain metadata about the database state

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA
Other supporting files include:

• Parameter Files – Configuration settings for startup

• Password Files – Securely store authentication credentials

Processes in Action:

• User Process: Represents client-side interactions

• Server Process: Executes SQL and manages data retrieval for users

Interview Questions
1. What is an Oracle Instance? How is it different from a database?

Answer:
An Oracle Instance is a combination of memory structures (SGA) and background processes
that manage database operations.
A Database, on the other hand, is a collection of physical files (data files, control files, redo log
files) stored on disk.

Instance = Memory + Processes


Database = Physical Storage (files)

2. What is the role of the SGA in Oracle Architecture?

Answer:
The System Global Area (SGA) is a shared memory region allocated when the instance starts. It
stores:

• Frequently accessed data blocks (Buffer Cache)

• Parsed SQL statements (Shared Pool)

• Transaction logs (Redo Log Buffer)

• Java objects (Java Pool)

• Backup operations (Large Pool)

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA
3. What are the key components of the SGA?

Answer:
Main components include:

• Database Buffer Cache – Stores copies of data blocks from datafiles

• Redo Log Buffer – Holds redo entries for recovery

• Shared Pool – Contains parsed SQL, PL/SQL, and execution plans

• Large Pool – Handles large memory allocations (e.g., RMAN backups)

• Java Pool – Supports Java code execution in the database

4. What is the function of the Redo Log Buffer and Redo Log Files?

Answer:

• Redo Log Buffer (in SGA): Temporarily stores changes made to the database.

• Redo Log Files: Permanently store redo entries written by Log Writer (LGWR) for
recovery.

Used for instance recovery in case of system failure.

5. Explain the role of background processes in Oracle.

Answer:
Important background processes include:

• SMON – Performs crash recovery & instance recovery

• PMON – Cleans up failed user sessions

• DBWR – Writes dirty buffers from SGA to datafiles

• LGWR – Writes redo entries from memory to redo log files

• CKPT – Signals DBWR to write checkpoints to control/data files

6. What is the purpose of the Control File in Oracle?

Answer:
The Control File is a binary file that tracks:

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA
• Database name and creation time

• File names and locations (data, redo logs)

• Checkpoint information

• Backup details

It is essential for database startup and recovery.

7. What happens when you start an Oracle Database?

Answer:
Startup goes through three stages:

1. Nomount – Reads initialization parameter file and starts instance

2. Mount – Reads control files

3. Open – Opens data files and allows user access

8. What is the role of the DBWR process?

Answer:
Database Writer (DBWR) writes modified (dirty) data blocks from the buffer cache in SGA to
datafiles on disk. This helps reduce disk I/O and improve performance.

9. What is the difference between User Process and Server Process?

Answer:

• User Process: Initiated by the client to connect to the database.

• Server Process: Works on behalf of the user process to execute SQL, retrieve data, and
perform DB operations.

10. What files are necessary to start an Oracle Database?

Answer:

1. Parameter file (init.ora or spfile.ora) – Startup configuration

2. Control file – Metadata of the DB

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/
Oracle DBA
3. Data files – Actual data

4. Redo log files – Changes for recovery

5. (Optional) Password file – Authenticates privileged users

Pavan Dhage
https://www.linkedin.com/in/pavandhage1/

You might also like