Les 01 core
-
Upload
femi-adeyemi -
Category
Technology
-
view
349 -
download
0
Transcript of Les 01 core
1Copyright © 2009, Oracle. All rights reserved.
Core Concepts and Tools of the Oracle Database
Copyright © 2009, Oracle. All rights reserved.1 - 2
Objectives
After completing this lesson, you should be able to:• Describe the core concepts of the Oracle Database
architecture with Automatic Storage Management (ASM)• Use configuration and management DBA tools• Describe the technical course environment
Copyright © 2009, Oracle. All rights reserved.1 - 3
Naming the Core Components of an Oracle Database Server
Database (Storage Structures)
Serverprocess
PGA
Userprocess
Instance
Memory Structures (System Global Area)
Process Structures
Client
ServerConnection
Copyright © 2009, Oracle. All rights reserved.1 - 4
Oracle Database Server Architecture Overview
Database (storage structures)
Serverprocess
PGA
Userprocess
Instance
Memory structures (System Global Area)
Process structures
Client
Server
Session
Connection
Copyright © 2009, Oracle. All rights reserved.1 - 6
Instance-Database Configurations
D1
D2
I1
I2I1 I2 I3
D
Clustered systemNonclustered system
Local storage
Shared storage
Copyright © 2009, Oracle. All rights reserved.1 - 7
Naming the Memory Structures of an Oracle Database
Assign these names:
Shared pool
Databasebuffercache
Streams pool
Large pool
Java pool
Stack
Space
KEEP buffer poolRecycle
buffer poolnK buffer
cache
User
Global
Area
Server process
Redo logbuffer
Program Global Area (PGA)
System Global Area (SGA)
Copyright © 2009, Oracle. All rights reserved.1 - 8
Oracle Database Memory Structures
Serverprocess 1
Shared poolDatabase
buffercache
Redo logbuffer
Streams poolLarge pool Java pool
Stack
Space
System Global Area (SGA)
Program Global Area (PGA)
Serverprocess 2
KEEP buffer pool
Recycle buffer pool
nK buffer cache
User
Global
Area
Stack
Space
User
Global
Area
PGA
Copyright © 2009, Oracle. All rights reserved.1 - 10
Process Architecture
• User process– Is the application or tool that connects to the Oracle
Database• Database processes
– 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
• Daemon/Application processes– Networking listeners– Grid Infrastructure daemons
Copyright © 2009, Oracle. All rights reserved.1 - 11
Process Structures
PMONSMON
Others
Instances (ASM and Database separate)
RECO
ARCn
DBWn LGWRCKPT
PGA
Userprocess
Serverprocess
Background processes
System Global Area (SGA)
Required:
ASMB RBALOptional:Listener
Grid Infrastructure Processes(ASM and Oracle Restart)
orarootagent
ohasd ocssd diskmon
oraagent cssdagent
Copyright © 2009, Oracle. All rights reserved.1 - 13
Adding Process Names
1. The ______process writes the dirty buffers to the data files.
2. The ______process writes the redo entries to the online redo log files.
3. The ______process writes checkpoint information in the control file and each data file header.
4. The ______process performs recovery on instance startup.
5. The ______process performs process recovery when a user process fails.
6. The ______process resolves in-doubt distributed transactions.
7. The ______processes copy redo log files to a designated storage device.
A. Checkpoint process (CKPT)
B. System monitor process (SMON)
C. Recoverer process (RECO)
D. Log writer process (LGWR)
E. Archiver processes (ARCn)
F. Process monitor process (PMON)
G. Database writer process (DBWn)
Copyright © 2009, Oracle. All rights reserved.1 - 14
• Oracle Grid Infrastructure is started by the OS init daemon.
• Oracle Grid Infrastructure installation modifies the /etc/inittab file to ensure startup every time the machine is started in the corresponding run level.
Process Startup Sequence
init.ohasd (root)
ohasd.binoraagent.binorarootagent.bindiskmon.bincssdagentocssd.bin
init
Grid InfrastructureWrapper Script
Grid InfrastructureDaemons and Processes
Operating SystemInit Daemon
# cat /etc/inittab..h1:35:respawn:/etc/init.d/init.ohasd run >/dev/null 2>&1 </dev/null
ASM instance Listener DB instance User-defined applications
Copyright © 2009, Oracle. All rights reserved.1 - 15
Database Storage Architecture
Online redo log files
Password file
Parameter file Archived redo log files
Control files Data files
Alert log and trace files
Backup files
Copyright © 2009, Oracle. All rights reserved.1 - 17
Logical and Physical Database Structures
Database
Logical Physical
Tablespace Data file
Segment
Extent
Oracle datablock
Storage system
• SAN
• NAS
• Exadata
• File system
• NFS
• ASM
• RAW
Copyright © 2009, Oracle. All rights reserved.1 - 19
Automatic Storage Management
• Is a portable and high-performancecluster file system
• Manages Oracle database files• Manages application files with ASM Cluster File System (ACFS)• Spreads data across disks
to balance load• Mirrors data in case of failures• Solves storage-management
challenges
ASM Cluster File
System
ASM Dynamic VolumeManager
ApplicationOracle
Database
Operating system
ASM Files for Oracle
Database
Automatic Storage Management
Copyright © 2009, Oracle. All rights reserved.1 - 20
ASM Storage Components
OracleDatabaseData file
ASMdisk group
ASM disk
ASM file
ASMextent
File systemor
Raw device
ASM
ASM allocationUnit
Copyright © 2009, Oracle. All rights reserved.1 - 21
ASM Instance
The ASM Instance is the process and memory components for ASM.
Other misc. processes
System Global Area (SGA) – memory
Sharedpool
Largepool
ASMcache
Freememory
Processes – CPU components
ASM instance
RBAL ARBn GMON Onnn PZ9n
MARK
Copyright © 2009, Oracle. All rights reserved.1 - 23
DBA Configuration Tools
Setting up the technical environment for this course included the following tasks and tools:• Installing and configuring the Oracle Grid Infrastructure for
a stand-alone server with the OUI, including:– Configuring a listener– Creating an ASM instance (+ASM) and configuring the
+DATA disk group– Configuring Oracle Restart
• Creating and configuring additional ASM disk groups (such as +FRA) with asmca
• Installing the Oracle Database 11g software with OUI• Creating the orcl Oracle database with dbcaNote: These tasks have already been performed for you.
Copyright © 2009, Oracle. All rights reserved.1 - 25
Management Framework and Related DBA Tools
The Oracle database management framework includes:• Database instance • Listener• Management interface:
– Management agent (when using Grid Control)
– Database Control
Related tools and commands include:SQL*Plus:
Listener Control utility:
Enterprise Manager Control utility:$ emctl status dbconsole$ emctl start dbconsole$ emctl stop dbconsole
$ lsnrctl status
SQL> startupSQL> shutdown immediate
Copyright © 2009, Oracle. All rights reserved.1 - 26
Facilitating Database Management with Oracle Restart
• Restarting Oracle components when the host computer restarts or after hardware or software failure
• Monitoring components and restarting them, if needed• For single-instance environments• Considering component dependencies:
– Mounting disk groups and starting the ASM instance before starting the database instance
– Soft dependency between the database instance and the listener
• Starting Oracle Restart with the crsctl utility • Managing Oracle Restart components with the srvctl
utility $ srvctl stop database –d orcl –o abort
Copyright © 2009, Oracle. All rights reserved.1 - 28
Quiz
Oracle Restart is installed and configured as part of an Oracle Grid Infrastructure for stand-alone server installation.1. True2. False
Copyright © 2009, Oracle. All rights reserved.1 - 29
Summary
In this lesson, you should have learned how to:• Describe the core concepts of the Oracle Database
architecture with ASM• Determine which DBA configuration and management
tools to use for which task• Describe the technical course environment
orcl +asm
DATAFRA
Enterprise ManagerCommand line