Top Banner
1 Copyright © 2005, Oracle. All rights reserved. Introduction
20

Less01 DB Architecture MB3

Dec 27, 2015

Download

Documents

Daniel Tarabic

Lectia 1
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Less01 DB Architecture MB3

1Copyright © 2005, Oracle. All rights reserved.

Introduction

Page 2: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-2

Course Objectives

After completing this course, you should be able to do the following:

• Install, create, and administer Oracle Database 10g

• Configure the database for an application

• Employ basic monitoring procedures

• Implement a backup and recovery strategy

• Move data between databases and files

Page 3: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-3

Suggested Schedule

1. Introduction

2. Installation

3. DB Creation

4. Instance

5. Storage

6. Users

7. Schema

8. Data & Concurrency

9. Undo

10. Security

11. Network

12. Proactive Maintenance

13. Performance

14. Backup & Recovery Concepts

15. Backup

16. Recovery17. Flashback18. Moving Data

Page 4: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-4

Lesson Objectives

After completing this lesson, you should be able to do the following:

• Describe the course objectives

• Explain the Oracle Database 10g architecture

Page 5: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-5

Oracle Products and Services

• Oracle databases

• Oracle Application Server

• Oracle applications

• Oracle Collaboration Suite

• Oracle Developer Suite

• Oracle services

Page 6: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-6

Oracle Database 10g:“g” Stands for Grid

• Global Grid Forum (GGF)

• Oracle’s grid infrastructure:– Low cost– High quality of service– Easy to manage

AutomaticStorage

Management

RealApplication

Clusters

OracleStreams

EnterpriseManager

Grid Control

Storagegrid

Databasegrid

Applicationgrid

Gridcontrol

Page 7: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-8

Oracle Database Architecture

An Oracle server:

• Is a database management system that provides an open, comprehensive, integrated approach to information management

• Consists of an Oracle instance and an Oracle database

Page 8: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-9

Database Structures

Storage structures

Memory structures

Process structures

Instance

System Global Area (SGA)

Background processes

Database files

DB structures - Memory - Process - Storage

Page 9: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-10

Oracle Memory Structures .

Java poolDatabase

buffer cacheRedo log

buffer

Shared pool Large pool

SGA

Streams pool

Serverprocess

1PGA

Serverprocess

2PGA

Backgroundprocess

PGA

DB structures> Memory

ProcessStorage

Page 10: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-12

Process Structures

• User process: Is started at the time a database user requests a connection to the Oracle server

• Server process: Connects to the Oracle instance and is started when a user establishes a session

• Background processes: Are started when an Oracle instance is started

Instance

SGA

Background

processes

Serverprocess

PGA

User process

DB structuresMemory

> Process Storage

Page 11: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-13

Oracle Instance Management

SystemMonitor(SMON)

DatabaseWriter

(DBWn)

LogWriter(LGWR)

ProcessMonitor(PMON)

Archiver(ARCn)

SGA

Java pool

Shared pool Large poolStreams pool

Databasebuffer cache

Redo log buffer

Checkpoint(CKPT)

Controlfiles

Datafiles

Redo logfiles

Archive log files

Page 12: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-14

Server Process and Database Buffer Cache

Buffers:

• Pinned

• Clean

• Free or unused

• Dirty

DBWn

Serverprocess

SGA

Databasebuffer cache

Data files

Page 13: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-15

Physical Database Structure .

Online redo log files

Password file

Parameter file Archive log files

Control files Data files

Alert and trace log files

Backup files

DB structuresMemoryProcess

> Storage

Page 14: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-17

Tablespaces and Data Files

• Tablespaces consist of one or more data files.

• Data files belong to only one tablespace.

USERS tablespace

Data file 1 Data file 2

Page 15: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-18

SYSTEM and SYSAUX Tablespaces

• The SYSTEM and SYSAUX tablespaces are mandatory tablespaces.

• They are created at the time of database creation.

• They must be online.

• The SYSTEM tablespace is used for core functionality (for example, data dictionary tables).

• The auxiliary SYSAUX tablespace is used for additional database components (such as the Enterprise Manager Repository).

Page 16: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-19

Segments, Extents, and Blocks

• Segments exist within a tablespace.

• Segments are made up of a collection of extents.

• Extents are a collection of data blocks.

• Data blocks are mapped to disk blocks.

Segment Extents Data blocks

Disk blocks

Page 17: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-20

Logical and Physical Database Structures

Database

Logical Physical

Tablespace Data file

OS block

Segment

Extent

Oracle datablock

Schema

Page 18: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-22

Course Examples: The HR Schema

REGIONSREGION_ID (PK)REGION_NAME

COUNTRIESCOUNTRY_ID (PK)COUNTRY_NAMEREGION_ID (FK)

LOCATIONSLOCATION_ID (PK)STREET_ADDRESSPOSTAL_CODECITYSTATE_PROVINCECOUNTRY_ID (FK)

DEPARTMENTSDEPARTMENT_ID (PK)DEPARTMENT_NAMEMANAGER_IDLOCATION_ID (FK)

JOBSJOB_ID (PK)JOB_TITLEMIN_SALARYMAX_SALARY

EMPLOYEESEMPLOYEE_ID (PK)FIRST_NAMELAST_NAMEEMAILPHONE_NUMBERHIRE_DATEJOB_ID (FK)SALARYCOMMISION_PCTMANAGER_ID (FK)DEPARTMENT_ID (FK)

JOB_HISTORYEMPLOYEE_ID (PK)START_DATE (PK)END_DATEJOB_ID (FK)DEPARTMENT_ID (FK)

REGIONS

COUNTRIES

LOCATIONS

DEPARTMENTS

JOBS

EMPLOYEES

JOB_HISTORY

Page 19: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-23

Database Architecture:Summary of Structural Components

• Memory structures:– System Global Area (SGA): Database buffer cache,

redo buffer, and various pools– Program Global Area (PGA)

• Process structures:– User process and Server process– Background processes: SMON, PMON, DBWn,

CKPT, LGWR, ARCn, and so on

• Storage structures:– Logical: Database, schema, tablespace, segment,

extent, and Oracle block– Physical: Files for data, parameters, redo, and OS

block

Page 20: Less01 DB Architecture MB3

Copyright © 2005, Oracle. All rights reserved.1-24

Summary

In this lesson, you should have learned how to:

• Install, create, and administer Oracle Database 10g

• Configure the database for an application

• Employ basic monitoring procedures

• Implement a backup and recovery strategy

• Move data between databases and files