You are on page 1of 4

Q.Describe Oracle architecture in brief.

A.The Oracle database has:


1.Logical layer: The components of the logical layer map the data to these physical components
2.Physical layer: The physical layer consists of the files that reside on the disk
Tablespaces and Datafiles
The database is divided into one or more logical pieces known as tablespaces. A tablespace is
used to logically group data together
The Database Schema: A collection of logical-structure objects, known as schema objects.
These schema objects consist of structures such as:
1.tables,
2.clusters,
3.indexes,
4.views,
5.stored procedures,
6.database triggers, and
7.sequences.
Segments, Extents, and Data Blocks
Within Oracle, the space used to store data is controlled by the use of logical structures. These
structures consist of the following:
1.Data blocks-A block is the smallest unit of storage in an Oracle database. (contains header
information concerning the block itself as well as the data)
2.Extents-Extents consist of data blocks.
3.Segments-A segment is a set of extents used to store a particular type of data.
The Oracle Instance has:
1.User processes
2.Oracle background processes
3.The shared memory
The Oracle Memory Structure contains:
1.The System Global Area (SGA)
2.The Data-Dictionary Cache
3.The Program Global Area (PGA)

Q.What is the function of SMON?


A.The SMON background process performs all system monitoring functions on the oracle
database.Each time oracle is re-started, SMON performs a warm start and makes sure that the
transactions that were left incomplete at the last shut down are recovered. SMON performs
periodic cleanup of temporary segments that are no longer needed.
Q.what are the different types of segment.
A.There are four types of segments used in Oracle databases:
1.data segments
2.index segments
3.rollback segments
4.temporary segments
Q.What is data segment?
A.Data Segments:
There is a single data segment to hold all the data of every non clustered table in an oracle
database. This data segment is created when you create an object with the CREATE
TABLE/SNAPSHOT/SNAPSHOT LOG command. Also, a data segment is created for a cluster
when a CREATE CLUSTER command is issued.The storage parameters control the way that its
data segments extents are allocated. These affect the efficiency of data retrieval and storage for
the data segment associated with the object.
Q.What is Index segment?
A.Index Segments:
Every index in an Oracle database has a single index segment to hold all of its data. Oracle
creates the index segment for the index when you issue the CREATE INDEX command. Setting
the storage parameters directly affects the efficiency of data retrieval and storage.
Q.What is rollback segment?
A.Rollback Segments
Rollbacks are required when the transactions that affect the database need to be undone.
Rollbacks are also needed during the time of system failures. The way the roll-backed data is
saved in rollback segment, the data can also be redone which is held in redo segment.A rollback
segment is a portion of the database that records the actions of transactions if the transaction
should be rolled back. Each database contains one or more rollback segments. Rollback
segments are used to provide read consistency, to rollback transactions, and to recover the
database.
Q.what are the types of rollbacks?
A.Types of rollbacks:
1.statement level rollback
2.rollback to a savepoint
3.rollback of a transaction due to user request
4.rollback of a transaction due to abnormal process termination
5.rollback of all outstanding transactions when an instance terminates abnormally
6.rollback of incomplete transactions during recovery.

Q.what are temporary segments?


A.Temporary Segments:
The SELECT statements need a temporary storage. When queries are fired, oracle needs area to
do sorting and other operation due to which temporary storages are useful.The commands that
may use temporary storage when used with SELECT are:GROUP BY, UNION, DISTINCT, etc.
Q.Explain SGA memory structures: Shared Pool, Database buffer Cache, Redo log Cache,
Large Pool Java Pool.
A.SGA (System Global Area) is a dynamic memory area of an Oracle Server. In SGA,the
allocation is done in granuels. The size of the SGA is dependent on SGA_MAX_SIZE
parameter.The memory structures contained by SGA are:1.Shared Pool This memory structure is divided into two sub-structures which are Library
Cache and Data Dictionary Cache for storing recently used PL/SQL statements and the recent
data definitions. The maximum size of the Shared Pool depends on the SHARED_POOL_SIZE
parameter.
2.Database Buffer Cache This memory structure improves the performance while fetching or
updating the recently used data as it stores the recently used datafiles. The size of this block is
decided by DB_BLOCK_SIZE.
3.Redo Log Buffer This memory structure is used to store all the changes made to the database
and its primarily used for the data recovery purposes. The size of this block is decided by
LOG_BUFFER.
4.Java Pool This memory structure is used when Java is installed on the Oracle server. Size that
can be used is stored in parameter named JAVA_POOL_SIZE.
5.Large Pool This memory structure is used to reduce the burden of the Shared Pool, as the
Session memory for the Shared Server, as the temporary storage for the I/O and for the backup
and restore operations or RMAN. Parameter that stores the maximum size is
LARGE_POOL_SIZE.
Q.What is SQL Loader? Explain the files used by SQL Loader to load file.
A.SQL*Loader is a bulk loader utility used for moving data from external files into the Oracle
database. SQL*Loader supports various load formats, selective loading, and multi-table
loads.When a control file is fed to an SQL*Loader, it writes messages to the log file, bad rows to
the bad file and discarded rows to the discard file.
1.Control file
The SQL*Loader control file contains information that describes how the data will be loaded. It
contains the table name, column datatypes, field delimiters, etc.controlfile.sql should be used to
generate an accurate control file for a given table.

2.Log File
The log file contains information about the SQL*loader execution. It should be viewed after each
SQL*Loader job is complete.
Q.Explain the methods provided by SQL Loader.
A.1.Conventional Path Load
2.Direct Path Load
Q.What is the logical structure of oracle?
A.1.Logical Database structures: They include tablespaces, schema objects, data blocks, extents
and segments.
2.Tablespaces:Database is logically divided into one or more tablespaces. Each tablespace
creates one or more datafiles to physically store data.
3.Schema objects : Schema objects are the structure that represents databases data. Schema
objects include structures such as tables, views, sequences, stored procedures, indexes,
synonyms, clusters and database links.
4.Data Blocks
disk.

ata block represents specific number of bytes of physical database space on

5.Extents:An extent represents continuous data blocks that are used to store specific data
information.
6.Segments:A segment is a set of extents allocated for a certain logical structure.
Q.what is the physical database structure?
A.Physical database structure
The physical database structure comprises of datafiles, redo log files and control files
1.Datafiles
Datafiles contain databases data. The data of logical data structures such as tables and indexes is
stored in datafiles of the database. One or more datafiles form a logical unit of database storage
called a tablespace.
2.Redo log files
The purpose of these files is to record all changes made to data. These files protect database
against failures.
3.Control files
Control files contain entries such as database name, name and location of datafiles and redo log
files and time stamp of database creation

You might also like