Exforsys.com
 
Home Tutorials Oracle 10g
 

Oracle 10g Free Training: Oracle Concepts and Database Architecture

 

Oracle 10g Free Training: Oracle Concepts and Database Architecture

Page 1 of 2
Oracle 10g Free Training: Oracle Concepts and  Database Architecture:This tutorial provides a brief overview of Architecture of Oracle database. It also gives an introduction to the concept of instance. The document discusses the structures that are used to define the physical and logical representations if Oracle Database.

Oracle Database Architecture


Oracle is an RDBMS (Relational Database Management System). The Oracle database architecture can be described in terms of logical and physical structures. The advantage of separating the logical and physical structure is that the physical storage structure can be changed without affecting the logical structure.


Logical Structure

The logical structure for Oracle RDBMS consists of the following elements:


  • Tablespace
  • Schema

Tablespace

The Oracle database consists of one or more logical portions called as ‘Tablespaces’. A tablespace is a logical grouping of related data.

A database administrator can use Tablespaces to do the following:


  • Control disk space allocation for database data.
  • Assign specific space quotas for database users.
  • Perform partial database backup or recovery operations.
  • Allocate data storage across devices to improve performance.

Each database has at least one Tablespace called SYSTEM Tablespace. As part of the process of creating the database, Oracle automatically creates the SYSTEM tablespace. Although a small database can fit within the SYSTEM tablespace, it's recommended that to create a separate tablespace for user data.

Oracle uses the SYSTEM tablespace to store information like the data dictionary. Data dictionary stores the metadata (or the data about data). This includes information like table access permissions, information about keys etc.


Data is stored in the database in form of files called as datafiles. Each Tablespace is a collection of one or more Datafiles. Each data file consists of ‘Data blocks’, ‘extents’ and ‘segments’.


Data Blocks

At the finest level of granularity, an ORACLE database's data is stored in data blocks (also called logical blocks, ORACLE blocks, or pages). An ORACLE database uses and allocates free database space in ORACLE data blocks.


Extents

The next level of logical database space is called an extent. An extent is a specific number of contiguous data blocks that are allocated for storing a specific type of information.


Segments

The level of logical database storage above an extent is called a segment. A segment is a set of extents that have been allocated for a specific type of data structure, and all are stored in the same tablespace. For example, each table's data is stored in its own data segment, while each index's data is stored in its own index segment. ORACLE allocates space for segments in extents. Therefore, when the existing extents of a segment are full, ORACLE allocates another extent for that segment. Because extents are allocated as needed, the extents of a segment may or may not be contiguous on disk, and may or may not span files.

An Oracle database can use four types of segments:


  • Data segment--Stores user data within the database.
  • Index segment--Stores indexes.
  • Rollback segment--Stores rollback information. This information is used when data must be rolled back.
  • Temporary segment--Created when a SQL statement needs a temporary work area; these segments are destroyed when the SQL statement is finished. These segments are used during various database operations, such as sorts.

Schema

The database schema is a collection of logical-structure objects, known as schema objects that define how you see the database's data. A schema also defines a level of access for the users. All the logical objects in oracle are grouped into a schema.

A scheme is a logical grouping of objects such as:


  • Tables
  • Clusters
  • Indexes
  • Views
  • Stored procedures
  • Triggers
  • Sequences

Physical Structure

The physical layer of the database consists of three types of files:


  1. One or more Datafiles
  2. Two or more redo log files
  3. One or more control files

Datafiles (.dbf files):


Datafiles store the information contained in the database. One can have as few as one data file or as many as hundreds of datafiles. The information for a single table can span many datafiles or many tables can share a set of datafiles. Spreading tablespaces over many datafiles can have a significant positive effect on performance. The number of datafiles that can be configured is limited by the Oracle parameter MAXDATAFILES.


Redo Log Files (.rdo & .arc):

Oracle maintains logs of all the transaction against the database. These transactions are recorded in files called Online Redo Log Files (Redo Logs). The main purpose of the Redo log files is to hold information as recovery in the event of a system failure. Redo log stores a log of all changes made to the database. The redo log files must perform well and be protected against hardware failures (through software or hardware fault tolerance). If redo log information is lost, one cannot recover the system.

When a transaction occurs in the database, it is entered in the redo log buffers, while the data blocks affected by the transactions are not immediately written to disk. In an Oracle database there are at least three or more Redo Log files.

Oracle writes to redo log file in a cyclical order i.e. after the first log file is filled, it writes to the second log file, until that one is filled. When all the Redo Log files have been filled, it returns to the first log file and begin overwrite its content with new transaction data. Note, if the database is running in the ARCHIVELOG Mode, the database will make a copy of the online redo log files before overwriting them.


Control Files (.ctl):

Control files record control information about all of the files within the database. These files maintain internal consistency and guide recovery operation. Control files contain information used to start an instance, such as the location of datafiles and redo log files; Oracle needs this information to start the database instance. Control files must be protected. Oracle provides a mechanism for storing multiple copies of control files. These multiple copies are stored on separate disks to minimize the potential damage due to disk failure. The names of the database’s control files are specified via the CONTROL_FILES initialization parameter.


Next Page: Oracle 10g Free Training: Oracle Concepts and Database Architecture - Page 2


Read Next: Oracle 10g Free Training:Creating Database Using Database Configuration Assistant (DBCA)



 

 

Comments


sanjeev111 said:

  this information is not completed, plz give brief
July 25, 2006, 7:50 am

jibankr1983 said:

  :)PLEASE MORE DIAGRAMATIC PRESENTATION
October 8, 2006, 12:53 am

TANMAYA PRADHAN said:

  hi,

This is a nice presentation of concepts.

but i have a doubt,

What is a backup and how we take backup?

i Hope i will get the answer very soon.

Thanks & Regards
Tanmaya Pradhan.







April 13, 2007, 6:08 am

Mudit k. Sharma said:

  I found this information very use full to understand the basic architecture of oracle.

Grate job done and also help full to start your jurnery for understanding the oracle.

Regards,

Mudit K. Sharma
July 24, 2007, 5:53 pm

Radha.M said:

  This information is very useful for the beginners to understand the oracle.This helps very much for the people who want to learn oracle.
Regards,
Madadi.Radha
August 14, 2007, 12:47 am

mohammadmartak said:

  if iam issued SELECT query to database, what process happen to SGA, which background proccess handle the query?
August 20, 2007, 9:34 am

Mandeep.A said:

  Wonderfull
September 27, 2007, 11:54 pm

T.somasekhar said:

  very good explain of back ground process
October 7, 2007, 2:36 am

kishorereddy said:

  very usefull for freshers
November 16, 2007, 12:03 pm

pradeep rai said:

  Its really usefull. Good sumerization of a big topic.
November 27, 2007, 12:22 am

murtuza.r said:

  Hi,
Backup is the procedure to secure your data/Information in other storage media or other destination. Incase of any crash you can restore it back and save the information which can be lost. There is some method from which you can take the backup but before that you need to understand the different type of backup. One is Physical backup(Cold backup) and other is Logical Backup(HOT BAckup). Cold backup is where you have to shutdown the database and copy the Datafile, redologfile and controlfile to other location/media. HOT backup in that you dont need to shutdown you database. just apply some commands online and you will be able to take the backup of those files. Like say you want to take the backup of control file, apply command "Alter database backup controlfile to 'filename' or to Trace." To take the backup of datafile,
"Alter tablespace begine backup;". Than copy all the datafiles pertaining to this tablespace in other location media and after copying all the datafile of that tablespace, apply another command which isa compulsory . "Alter tablespace < tablespace_name> end backup." for more information Tanmaya , just mail me on murtuza231@rediffmail.com.
November 28, 2007, 11:30 pm

murtuza.r said:

  @mohammadmartak

When you fire the SQL Query, Besically there are three steps involved in it.
1) Parse
2) Execution
3) Fetch
In Step(1) : During the parse phase, the SQL statement is passed from user process to Oracle and a parsed representation of the SQL statement is loaded into a shared SQL area. Parsing is the process of

1) translating SQL statement, verifying it to be a valid statement
2) performing data distionary lookups to check table and column defination
3) acquiring parse locks on the required objects so that their defination do not change during the statement's parsing.
4) checking previleges to access referenced schema objects.
5) determining the optimal execution plan for the statement.
6) loading it into a shared SQL area.

A SQL statement is parsed only if a shared SQL area for an identical SQL statement does not exist in the shared pool. In this case a new shared SQL area is allocated and the statement is parsed.
Step(2) ...During execute phase, at this point Oracle has all necessary information and resources, so the statement is executed.
Step(3) .. In the fetch phase, rows are selected and ordered(if requested by the query), and each successive fetch retrieves another row of the result, until the last row has been fetched.
November 30, 2007, 4:11 am

sridhar36 said:

  Highly Appreciate the Work , the Language Used was very easy to understand and make others understand
December 23, 2007, 7:21 am

MONA said:

  Highly Appreciate the Work ,Its really usefull.
monaabdellatif;
January 14, 2009, 5:02 am

Ashraf said:

  really usefull
January 27, 2009, 6:30 am

Rajalakshmi said:

  Its very useful for beginners. But a diagrammatic representation would have been good to explain the Oracle DB Architecture.
February 6, 2009, 1:34 am

Sampson Mensah said:

  Hi, this is very wonderful, even it a kind motivation and useful for beginners like us will know more and excel higher in the Database management with DBA itself. Please i have a problem with granting a previllages to user i have created. Also i am very interested in your programe, may i know please if there could be any posible way for me to enjoy these intensive free training your are making.

Thank you all

I will be expecting your kind answer in my 'inbox' of the e-mail i have provided.

Thank you once again.
February 19, 2009, 11:23 am

Hannibal said:

  Can any one pls come up with the answer for the following questions and i would really appreciate the effort.

1)when a recovery takes place for media failure the reco process recovers using archive file, does it use db cache to write(dbwr) the lost information to datafile.(b'coz no other process can write the datafile) and where to find information.

2)export utility uses which memory area.

3)what's the status of a cursor(implicit) in shared pool.

thanks in advance.









April 3, 2009, 3:10 pm

foster shadrack said:

  I want to learn to build a platform, what do I need to start with first? I want to manage data's. How can I backup files and directories?

Thanks and better regards
April 6, 2009, 11:53 am

ora10g said:

  Can anyone please tell me what type of Oracle 10g backup strategy we use in a real time scenario?
April 16, 2009, 4:11 am

Akila said:

  Hi, This is a nice documentation for a beginners who doesn't know ABCD in oracle. Each line has important information. Good Work.
June 15, 2009, 4:00 pm

clinch said:

  The entire information was good.........but diagrametic representation was not there........
January 24, 2010, 8:37 am

Post Your Comment:

Members Please Login
Your Name:*
e-mail ID:(required for notification)*
Image Verification: 
 
 Subscribe    

Sponsored Links

 

Subscribe via RSS


Get Daily Updates via Subscribe to Exforsys Free Training via email


Get Latest Free Training Updates delivered directly to your Inbox...

Enter your email address:


 

Subscribe to Exforsys Free Training via RSS
 

 
Partners -  Privacy and Legal Policy -  Site News -  Contact   Sitemap  

Copyright © 2000 - 2010 exforsys.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape