Top Banner
Oracle10g RAC Service Oracle10g RAC Service Architecture Architecture Overview of Real Application Overview of Real Application Cluster Ready Services, Nodeapps, Cluster Ready Services, Nodeapps, and User Defined Services and User Defined Services
31

Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Dec 28, 2015

Download

Documents

Solomon Harrell
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: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Oracle10g RAC Service Oracle10g RAC Service ArchitectureArchitecture

Overview of Real Application Overview of Real Application Cluster Ready Services, Nodeapps, Cluster Ready Services, Nodeapps, and User Defined Servicesand User Defined Services

Page 2: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

OverviewOverview

Service ArchitectureService Architecture Cluster Ready Services (CRS)Cluster Ready Services (CRS) NodeappsNodeapps User defined ServicesUser defined Services ASM ServicesASM Services Internally Managed ServicesInternally Managed Services Monitoring ServicesMonitoring Services

Page 3: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

RAC Service ArchitectureRAC Service Architecture

Oracle 10g RAC features a service Oracle 10g RAC features a service based architecturebased architecture

This is an improvement over 9i RAC This is an improvement over 9i RAC in several waysin several ways Increased flexibilityIncreased flexibility Increased manageabilityIncreased manageability Improvements in High AvailabilityImprovements in High Availability Enables 10g Grid DeploymentEnables 10g Grid Deployment

Page 4: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

RAC Services and High RAC Services and High AvailabilityAvailability Oracle Services facilitate high availability Oracle Services facilitate high availability

of databases and related applicationsof databases and related applications If key database resources become If key database resources become

unavailable (network, storage, etc.):unavailable (network, storage, etc.): Instances and Services will be relocated to Instances and Services will be relocated to

another nodeanother node The “failed” node will be rebootedThe “failed” node will be rebooted

By default, after any server boot-up, By default, after any server boot-up, Oracle attempts to restart all services on Oracle attempts to restart all services on the nodethe node

Page 5: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Cluster Ready ServicesCluster Ready Services Manage the RAC ClusterManage the RAC Cluster Several Different ServicesSeveral Different Services

OracleCRSServiceOracleCRSService Oracle CSServiceOracle CSService OracleEVMServiceOracleEVMService OraFenceServiceOraFenceService

Required for RAC installationRequired for RAC installation Installed in its own CRS_HOMEInstalled in its own CRS_HOME

Page 6: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

CRS BasicsCRS Basics

Used to manage RACUsed to manage RAC Only one set of CRS Daemons per Only one set of CRS Daemons per

systemsystem Multiple instances share the same CRSMultiple instances share the same CRS CRS runs as both root and Oracle usersCRS runs as both root and Oracle users

CRS must be running before RAC can CRS must be running before RAC can startstart

Page 7: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

CRS ManagementCRS Management

Started automaticallyStarted automatically Can stop and start manuallyCan stop and start manually

Start the OracleCRSServiceStart the OracleCRSService Stop the OracleCRSServiceStop the OracleCRSService

Uses the voting disk and OCR (Oracle Uses the voting disk and OCR (Oracle Cluster Repository)Cluster Repository)

Requires 3 network addressesRequires 3 network addresses PublicPublic PrivatePrivate Virtual PublicVirtual Public

Page 8: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

CRS ServicesCRS Services

OracleCRSServiceOracleCRSService Cluster Ready Services DaemonCluster Ready Services Daemon

OracleCSServiceOracleCSService Oracle Cluster Synchronization Service Oracle Cluster Synchronization Service

DaemonDaemon OracleEVMServiceOracleEVMService

Event Manager DaemonEvent Manager Daemon OraFenceServiceOraFenceService

Process MonitorProcess Monitor

Page 9: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Cluster Ready Services Cluster Ready Services DaemonDaemonOracleCRSServiceOracleCRSService Runs as Administrator userRuns as Administrator user Automatically restartedAutomatically restarted Manages Application ResourcesManages Application Resources Starts, stops and fails-over application Starts, stops and fails-over application

resourcesresources Maintains the OCR (Oracle Cluster Maintains the OCR (Oracle Cluster

Repository)Repository) Keeps state information in the OCRKeeps state information in the OCR

Page 10: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Oracle Cluster Oracle Cluster Synchronization Service Synchronization Service DaemonDaemonOracleCSServiceOracleCSService Runs as Administrator userRuns as Administrator user Maintains the heartbeat (failure causes Maintains the heartbeat (failure causes

system reboot)system reboot) ProvidesProvides

Node MembershipNode Membership Group AccessGroup Access Basic Cluster LockingBasic Cluster Locking

Can integrate with 3Can integrate with 3rdrd party clustering party clustering products or run standaloneproducts or run standalone

OracleCSService also works with non-RAC OracleCSService also works with non-RAC systemssystems

Page 11: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Event Manager DaemonEvent Manager DaemonOracleEVMServiceOracleEVMService Runs as Administrator userRuns as Administrator user Restarts on failureRestarts on failure Generates EventsGenerates Events Starts the racgevt thread to invokes Starts the racgevt thread to invokes

Server CalloutsServer Callouts

Page 12: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Process Monitor Process Monitor OraFenceServiceOraFenceService Runs as Administrator userRuns as Administrator user Locked in memory to monitor the clusterLocked in memory to monitor the cluster Provides I/O fencingProvides I/O fencing OraFenceService periodically monitors OraFenceService periodically monitors

cluster status, and can reboot the node if a cluster status, and can reboot the node if a problem is detected problem is detected

An OraFenceService failure results in An OraFenceService failure results in Oracle Clusterware restarting the nodeOracle Clusterware restarting the node

Page 13: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

RACGRACG RACG is a behind-the-scenes process RACG is a behind-the-scenes process

(or thread) that extends clusterware (or thread) that extends clusterware to support Oracle-specific to support Oracle-specific requirements and complex requirements and complex resources.resources.

Runs server callout scripts when FAN Runs server callout scripts when FAN events occur. events occur.

Runs as processes (or threads), not Runs as processes (or threads), not as a service (racgmain.exe, as a service (racgmain.exe, racgimon.exe)racgimon.exe)

Page 14: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Cluster Ready ServicesCluster Ready ServicesManagementManagement

Log FilesLog Files OracleCRSServiceOracleCRSService

%ORA_CRS_HOME%\log\hostname\crsd%ORA_CRS_HOME%\log\hostname\crsd

Oracle Cluster Registry (OCR)Oracle Cluster Registry (OCR) %ORA_CRS_HOME%log\hostname\ocr%ORA_CRS_HOME%log\hostname\ocr

OracleEVMServiceOracleEVMService %ORA_CRS_HOME%\log\hostname\evmd%ORA_CRS_HOME%\log\hostname\evmd

OracleCSServiceOracleCSService %ORA_CRS_HOME%log\hostname\cssd%ORA_CRS_HOME%log\hostname\cssd

RACGRACG %ORA_CRS_HOME%log\hostname\racg%ORA_CRS_HOME%log\hostname\racg

Page 15: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Nodeapp ServicesNodeapp Services Nodeapps are a standard set of Oracle Nodeapps are a standard set of Oracle

application services that are automatically application services that are automatically launched for RAClaunched for RAC Virtual IP (VIP)Virtual IP (VIP) Oracle Net ListenerOracle Net Listener Global Services Daemon (GSD)Global Services Daemon (GSD) Oracle Notification Service (ONS)Oracle Notification Service (ONS)

Nodeapp services run on each nodeNodeapp services run on each node Can be relocated to other nodes through the Can be relocated to other nodes through the

virtual IPvirtual IP

Page 16: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

VIP (Virtual IP)VIP (Virtual IP) Creates a virtual IP address used by the Creates a virtual IP address used by the

ListenerListener The virtual IP address fails over between The virtual IP address fails over between

nodesnodes Multiple virtual IP addresses can exist on Multiple virtual IP addresses can exist on

the same system (during failover)the same system (during failover) Independent of the Oracle InstanceIndependent of the Oracle Instance

Potential Problem if more than one database Potential Problem if more than one database per nodeper node

Page 17: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Global Services Daemon Global Services Daemon (GSD)(GSD) The daemon which executes SRVCTL The daemon which executes SRVCTL

commandscommands GSD receives requests from SRVCTL to GSD receives requests from SRVCTL to

execute administrative tasks, such as execute administrative tasks, such as startup or shutdownstartup or shutdown

The command is executed locally on each The command is executed locally on each node, and the results are sent back to node, and the results are sent back to SRVCTL.SRVCTL.

The daemon is installed on the nodes by The daemon is installed on the nodes by default. It is important that you do not kill default. It is important that you do not kill this process and it should not be deleted. this process and it should not be deleted.

Page 18: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

ListenerListener Server-side component of Oracle NetServer-side component of Oracle Net Listens for incoming client connection Listens for incoming client connection

requestsrequests Manages the traffic to the server; when a Manages the traffic to the server; when a

client requests a network session with a client requests a network session with a server, the listener actually receives the server, the listener actually receives the request and brokers the client requestrequest and brokers the client request

If the client's information matches the If the client's information matches the listener's information, then the listener listener's information, then the listener grants a connection to the server. grants a connection to the server.

Page 19: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Oracle Notification Service Oracle Notification Service (ONS)(ONS) The Oracle Notification Service is The Oracle Notification Service is

installed automatically on each RAC installed automatically on each RAC node as a Node Applicationnode as a Node Application

ONS starts automatically with each ONS starts automatically with each bootboot

ONS uses a simple push/subscribe ONS uses a simple push/subscribe method to publish event messages method to publish event messages to all RAC nodes with active ONS to all RAC nodes with active ONS daemonsdaemons

Page 20: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

ONS and Fast Application ONS and Fast Application NotificationNotification ONS can be configured to run on ONS can be configured to run on

nodes hosting client or mid-tier nodes hosting client or mid-tier applicationsapplications

ONS is the key component of Fast ONS is the key component of Fast Application Notification (FAN)Application Notification (FAN) Can be utilized to extend RAC high Can be utilized to extend RAC high

availability and load balancing to mid-availability and load balancing to mid-tier applicationstier applications

Independent of True Application Independent of True Application FailoverFailover

Less reliance on network configurationLess reliance on network configuration

Page 21: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

User Defined ServicesUser Defined Services User defined, named services may be User defined, named services may be

created to manage database resources created to manage database resources that are associated with application that are associated with application workloadsworkloads

One or more database instances may be One or more database instances may be mapped to a single servicemapped to a single service

A database instance may be assigned to A database instance may be assigned to one or more servicesone or more services

The Automated Workload Repository may The Automated Workload Repository may be used to monitor Service metricsbe used to monitor Service metrics

Page 22: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

User Defined Services and User Defined Services and FailoverFailover Services can be defined with Services can be defined with

preferred and alternate instancespreferred and alternate instances A service may be assigned to start on A service may be assigned to start on

preferred instancespreferred instances The same service may have alternate The same service may have alternate

instances assigned for failoverinstances assigned for failover If multiple services are assigned for the If multiple services are assigned for the

same database, the preferred and same database, the preferred and alternate instance assignments may be alternate instance assignments may be different for each servicedifferent for each service

Page 23: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Automatic Storage Automatic Storage Management ServicesManagement Services Automatic Storage Management (ASM) is Automatic Storage Management (ASM) is

a storage option for creating and a storage option for creating and managing databasesmanaging databases ASM operates like a Logical Volume Manager ASM operates like a Logical Volume Manager

between the physical storage and the between the physical storage and the database.database.

A small, automatically managed Oracle A small, automatically managed Oracle database instance is created on each node (if database instance is created on each node (if ASM is chosen as a storage option)ASM is chosen as a storage option)

ASM instances start automatically as Oracle ASM instances start automatically as Oracle servicesservices

Page 24: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Internally Managed Internally Managed ServicesServices When the Global Services Daemon is started as When the Global Services Daemon is started as

a part of the Node Applications, it in turn a part of the Node Applications, it in turn launches key internally managed serviceslaunches key internally managed services The Global Cache Service manages Cache Fusion and The Global Cache Service manages Cache Fusion and

in-memory data buffersin-memory data buffers The Global Enqueue Service manages inter-instance The Global Enqueue Service manages inter-instance

locking and RAC recoverylocking and RAC recovery GCS and GES show up as OS processes or GCS and GES show up as OS processes or

threads, but GSD is the only service that can be threads, but GSD is the only service that can be externally controlledexternally controlled

GCS and GES together manage a set of “virtual” GCS and GES together manage a set of “virtual” tables in memory, called the Global Resouce tables in memory, called the Global Resouce DirectoryDirectory

Page 25: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Global Cache Service Global Cache Service (GCS)(GCS) The controlling process that implements Cache Fusion.The controlling process that implements Cache Fusion. Manages the status and transfer of data blocks across the Manages the status and transfer of data blocks across the

buffer caches of all instances.buffer caches of all instances. Tightly integrated with the buffer cache manager to Tightly integrated with the buffer cache manager to

enable fast lookup of resource information in the Global enable fast lookup of resource information in the Global Resource Directory.Resource Directory.

Maintains the block mode for blocks in the global role.Maintains the block mode for blocks in the global role. Employs various background processes (or threads) such Employs various background processes (or threads) such

as the Global Cache Service Processes (LMSn) and Global as the Global Cache Service Processes (LMSn) and Global Enqueue Service Daemon (LMD). Enqueue Service Daemon (LMD).

Page 26: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Global Enqueue Service Global Enqueue Service Monitor (LMON)Monitor (LMON) Background process that monitors Background process that monitors

the entire cluster to manage global the entire cluster to manage global resources.resources.

Manages instance and process Manages instance and process expirations and recovery for GCS.expirations and recovery for GCS.

Handles the part of recovery Handles the part of recovery associated with global resourcesassociated with global resources

Page 27: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Global Resource DirectoryGlobal Resource Directory

The data structures associated with global The data structures associated with global resources. It is distributed across all instances in resources. It is distributed across all instances in a cluster. a cluster.

Global Cache Service and Global Enqueue Global Cache Service and Global Enqueue Service maintain the Global Resource Directory Service maintain the Global Resource Directory to record information about resources and to record information about resources and enqueues held globally. enqueues held globally.

The Global Resource Directory resides in The Global Resource Directory resides in memory and is distributed throughout the memory and is distributed throughout the cluster to all nodes. In this distributed cluster to all nodes. In this distributed architecture, each node participates in architecture, each node participates in managing global resources and manages a managing global resources and manages a portion of the Global Resource Directory. portion of the Global Resource Directory.

Page 28: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Monitoring RAC ServicesMonitoring RAC Services %ORA_CRS_HOME%\bin\crs_stat%ORA_CRS_HOME%\bin\crs_stat

NAME=ora.rac1.gsd NAME=ora.rac1.gsd TYPE=application TYPE=application TARGET=ONLINE TARGET=ONLINE STATE=ONLINE STATE=ONLINE NAME=ora.rac1.oem NAME=ora.rac1.oem TYPE=application TYPE=application TARGET=ONLINE TARGET=ONLINE STATE=ONLINE STATE=ONLINE NAME=ora.rac1.ons NAME=ora.rac1.ons TYPE=application TYPE=application TARGET=ONLINE TARGET=ONLINE STATE=ONLINE STATE=ONLINE

Page 29: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

Monitoring RAC ServicesMonitoring RAC Services Creating a tabular report:Creating a tabular report: %ORA_CRS_HOME%\bin\crs_stat -t%ORA_CRS_HOME%\bin\crs_stat -t

NameName Type Type Target Target State State Host Host --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

------- ------- ora.rac1.gsd ora.rac1.gsd application application ONLINE ONLINE ONLINE ONLINE

rac1rac1ora.rac1.oemora.rac1.oem application application ONLINE ONLINE ONLINEONLINE

rac1rac1ora.rac1.ons ora.rac1.ons application application ONLINE ONLINE ONLINE ONLINE

rac1rac1ora.rac1.vipora.rac1.vip application application ONLINE ONLINE ONLINEONLINE

rac1rac1ora.rac2.gsd ora.rac2.gsd application application ONLINE ONLINE ONLINE ONLINE

rac2rac2ora.rac2.oemora.rac2.oem application application ONLINE ONLINE ONLINEONLINE

rac2rac2ora.rac2.ons ora.rac2.ons application application ONLINE ONLINE ONLINE ONLINE

rac2rac2ora.rac2.vipora.rac2.vip application application ONLINE ONLINE ONLINEONLINE

rac2rac2

Page 30: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

ReviewReview What advantages does a service What advantages does a service

based architecture offer?based architecture offer? What four services comprise What four services comprise

Cluster Ready Services?Cluster Ready Services? Nodeapps consists of which four Nodeapps consists of which four

applications?applications? True or False: a database instance True or False: a database instance

may be assigned to multiple may be assigned to multiple servicesservices

Page 31: Oracle10g RAC Service Architecture Overview of Real Application Cluster Ready Services, Nodeapps, and User Defined Services.

SummarySummary Service ArchitectureService Architecture Cluster Ready Services (CRS)Cluster Ready Services (CRS)

OracleCRSServiceOracleCRSService OracleCSServiceOracleCSService OracleEVMServiceOracleEVMService OraFenceServiceOraFenceService

NodeappsNodeapps VIPVIP ListenerListener GSDGSD ONSONS

User defined ServicesUser defined Services ASM ServicesASM Services Internally managed servicesInternally managed services

Global Cache ServiceGlobal Cache Service Global Enqueue ServiceGlobal Enqueue Service Global Resource DirectoryGlobal Resource Directory

Monitoring ServicesMonitoring Services