Flex ASM and Flex Cluster
Flex ASM and Flex Cluster
PRESENTER
Y V RaviKumar
Oracle ACE & Oracle Certified Master (OCM)
Patterns 1
ORACLE CERTIFIED MASTER (OCM)
http://education.oracle.com/education/otn/10g_OCM_17_Jun_11/ykumar.htm
ORACLE ACE
https://apex.oracle.com/pls/apex/f?p=19297:4:::NO:4:P4_ID:13023
ABOUT ME
AUTHOR OF ORACLE TECHNOLOGY NETWORK (OTN) ARTICLES
http://www.oracle.com/tecchnetwork/es/articles/index.html - (17 Articles for OTN Spanish)
http://www.oracle.com/tecchnetwork/pt/articles/index.html - (14 Articles for OTN Portuguese)
http://www.oracle.com/tecchnetwork/articles/index.html - - ( 2 Articles for OTN English)
CO-FOUNDER OF
http://www.oraworld-team.com/
Patterns 2
ORACLE
Flex ASM and Flex Cluster
Patterns 3
ARCHITECTURE OF ASM
HARDWARE HARDWARE
Patterns 4
Oracle 10g RAC – VD & OCR Locations
Patterns 5
Oracle 11g RAC – VD & OCR Locations
Patterns 6
Oracle 12c RAC – VD & OCR Locations
Patterns 7
CAPABILITIES OF ASM
Database Database Database Database Database
Instance Instance Instance Instance Instance
Oracle
RAC
Servers
Database Database Database
1-1 ASM to SERVER
File 3 File 4
File 1 File 2
WIDE FILE STRIPING
Disk1 Disk 2 Disk 3 Disk 4 Disk 5 Disk 6 Disk 7
Patterns 8
AUTOMATIC STORAGE MANAGEMENT (ASM) OVERVIEW
Current State
RAC CLUSTER
Database Instance
INSTANCES TO
SERVERS Node1 ASM Node2 ASM Node3 ASM Node4 ASM Node5 ASM
Patterns 9
Oracle Database 11gR2 with ASM
Patterns 10
Oracle Database 11gR2 with ASM
Patterns 11
Oracle Database 11gR2 with ASM
Patterns 12
Oracle Database 11gR2 with ASM
[oracle@rac1 ~]$ srvctl stop asm -n rac1 -o abort -f THE STATUS OF ASM & RAC
CHECK
[oracle@rac1 ~]$ srvctl status asm DATABASE INSTANCE (RAC1)
ASM is running on rac2
[oracle@rac1 ~]$ ps -ef | grep pmon
Patterns 13
Oracle Database 11gR2 with ASM
SUMMARY
The database instance is strongly linked to the ASM instance
If an ASM instance fails so will the database instance on the
same node
Patterns 14
FLEX ASM: ELIMINATE 1:1 SERVER MAPPING
RAC Cluster
Database Instance
Node1
Node1 Node2 Node5
runs
runs as
as runs as runs as
ASM
ASM Client
Client ASM Client ASM Client
to
to Node4
Node2 to Node3 to Node4
ASM Cluster Pool of Storage
SHARED DISK Disk Group A Disk Group B ASM Disk
GROUPS
Patterns 15
Oracle Database 12cR1 with FLEX ASM
>>>
IN INSTANCE 1 (RAC 1)
[oracle@oel6-112-rac1 Desktop]$ asmcmd
Oracle Database 12cR1 with FLEX ASM CHECK IF ORACLE FLEX ASM IS ENABLED
ASMCMD> showclustermode OR NOT (RAC1)
ASM cluster : Flex mode enabled
ASMCMD> showclusterstate
Normal
ASMCMD> exit
>>>
DATABASE INSTANCE1 (RAC1)
[oracle@oel6-112-rac1 Desktop]$ crsctl check cluster
CRS-4535: Cannot communicate with Cluster Ready Services
CRS-4529: Cluster Synchronization Services is online
CHECK STATUS OF CLUSTER
CRS-4533: Event Manager is online
SERVICES IN RAC DATABASE
INSTANCE1 (RAC1)
[oracle@oel6-112-rac1 Desktop]$ ps -ef | grep pmon
oracle 3813 1 0 17:40 ? 00:00:00 mdb_pmon_-MGMTDB
oracle 5806 1 0 17:42 ? 00:00:00 ora_pmon_orcl1
oracle 6193 1 0 17:42 ? 00:00:00 apx_pmon_+APX1
[oracle@oel6-112-rac1 Desktop]$
CHECK STATUS OF ASM & RAC
DATABASE IN INSTANCE1
NOTE
(RAC 1)
Here a database instance is associated with the specific ASM instance running
in the specific node. If in case due to some reason if the ASM instance was
unable to be brought up/services goes down, still the database instance can be
brought up as the database instance will look for ASM instance running in the
same cluster.
>>>
Oracle Database 12cR1 with FLEX ASM
Patterns 19
Oracle Database 12cR1 with FLEX ASM
Patterns 20
Oracle Database 12cR1 with FLEX ASM
Patterns 21
Oracle Database 12cR1 with FLEX ASM
ASMCMD> lsdg
State Type Rebal Sector Block AU Total_MB Free_MB
Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name
MOUNTED EXTERN N 512 4096 1048576 15342 4782
0 4782 0 Y DATA/
ASMCMD>
SUMMARY
The database instance was using a dedicated ASM instance and that
ASM instance was forced to stop working simulating a failure, so the
database instance reconnected to an existent ASM instance on another
node, for this example node 2 (rac2).
Patterns 22
FLEX ASM: SUPPORTING ORACLE DATABASE 11g
RAC CLUSTER
Database Instance
Node1 ASM Node2 ASM Node3 ASM Node4 ASM Node5 ASM
Patterns 23
Oracle FLEX CLUSTER
Comprises of a Hub and Leaf architecture Depicts a typical Oracle flex cluster with four Leaf nodes and two Hub
nodes. In a nutshell Oracle Flex Cluster requires Oracle Flex ASM.
where in only the Hub nodes will only have
direct access to Oracle Cluster Registry
(OCR) and Voting Disk (VD)
However application can access the
database via Leaf nodes without ASM
instance NOT running on Leaf nodes
The connection to the database is through
Hub making it transparent for the
application
Patterns 24
HUB NODES & LEAF NODES
Hub Nodes
They are connected among them via private network and have direct access to
the shared storage just like previous versions. These nodes are the ones that
access the Oracle Cluster Registry (OCR) and Voting Disk (VD) directly.
Leaf Nodes
These nodes are lighter and are not connected among them, neither access the
shared storage like the Hub Nodes. Each Leaf Node communicates with the Hub
Node that is attached to, and its connected to the cluster via the Hub Node that
is linked to.
Patterns 25
FLEX ASM & FLEX CLUSTER
Flex ASM Flex CLUSTER
Higher Availability (DB Less complex configuration and management for
instances can use remote ASM non-database nodes
Less complex configuration for Non-Database
instances)
nodes, such as Processing Nodes, Application /
• Planned or Unplanned
Web Server Nodes etc.
downtime
Reduces per-node ASM
instance overhead
• ASM only needs to run on 3
nodes in the cluster
Facilitates DB, Cluster & server
consolidation
Multiple DB’s & applications in
a cluster
Patterns 26
PREVIOUS ASM CLUSTER
Cluster
Server Server
Patterns 27
NEW ASM CLUSTER
Eliminates requirement for an ASM instance on every cluster
server Cluster
Server Server Server Server
ASM
ASM
Flex Features
Increase maximum number of Disk Groups to 511 (Previous
limit was 63)
Command for renaming ASM Disk
ASM Relocate Command
Clients are automatically relocated to another instance if
an Oracle ASM instance fails
When necessary, Clients can be manually relocated
using the ALTER SYSTEM RELOCATE CLIENT command
Patterns 31
New Option in Grid Infrastructure
Patterns 32
Conversion of Standard Cluster to
Oracle Flex ASM Cluster
Patterns 33
Patterns 34
CHECK CLUSTER MODE AND CLUSTER STATE AFTER
LOGGING INTO ASMCMD PROMPT
[oracle@racnroll1 ~]$ asmcmd
ASMCMD> showversion
ASM version : 12.1.0.1.0
ASMCMD>showclusterstate
Normal
ASMCMD>showclustermode
ASM cluster : Flex mode enabled
Patterns 35
ORACLE
Flex ASM and Flex Cluster
Patterns 36