2
Audience Poll
3
Agenda
Brief ASM Overview
<Insert Picture Here>
Simplified Technology Stack
4
What is Oracle ASM?
Application
Application Oracle
OracleDatabase
Database
File
FileSystem
System
ASM
ASM
Logical
LogicalVolume
VolumeManager
Manager
Operating
OperatingSystem
System Operating
OperatingSystem
System
Hardware
Hardware Hardware
Hardware
ASM Benefits
I/O is spread evenly across diskgroup disks
Prevents hot spots and maximizes performance.
ASM eliminates need for over provisioning and maximizes
storage utilization
Great driver for database consolidation.
Rebalance - online redistribution of extents
Initiate with incremental addition/removal of storage
Can leverage ASM redundancy or 3rd party RAID
functionality.
Supports single instance databases as well as RAC.
Various tools to manage ASM
EM, asmcmd, asmca, Sql*Plus
Reduces overall Oracle Database TCO without
compromising performance or availability.
6
Screen reader hint: This
slide contains a diagram that
is explained in the speaker
notes.
11
ASM Cluster File System (ACFS)
Overview - Metalink Doc ID: 948187.1
12
ACFS Architecture
ASM Instance
rd
Database & 3 Party
ACFS
Clusterware File System
Files
Files Files
Disk Group Dynamic Volume
Practical Usages of ACFS
Oracle database installation binaries
RAC or single instance ORACLE_HOME directories
Database exports
Database logs and trace files
File based database objects
UTL_FILE_DIR location
Directories used by extproc routines
Directory objects for external BFILES and external tables
Application logs
Shared documents
Report output
Data dumps
14
ACFS
Cost Savings Use Cases
15
ACFS for E-Business Suite Customers
NFS APPLTOP
Concurrent Manager
Each node NFS Mount File System Output and
UTL_FILE_DIR
Forms Concurrent Web App
Server Manager APPLPTMP
Server Server
APPLTMP
APPLCFS/OUT
APPLCFS/LOG
16
Dynamically Resize ACFS
Reduce Application Downtime
18
Resize ACFS on the fly
No need to kick off the users to increase file system size
Command Function
acfsutil info Display new ACFS file and file system features (ACFS,
snapshots, registry, size) and information
Command-line syntax
# /sbin/acfsutil size +4G -d
/dev/asm/lobdata_db1-212
/apps/oracle/product/11.2.0/db_1acfsutil size:
new file system size: 10737418240 (10240MB)
19
ACFS Read-Only Snapshots
ACFS snapshot is an online, read-only, point in time copy of an
ACFS file system
The snapshot copy is initially sparse and merely references the
storage allocation information maintained by the file system
Automatically built when filesystem is created
Snapshot storage is maintained within the file system
Before an ACFS file extent is modified/deleted, its current value is
copied to the snapshot.
Copy-On-Write (COW) technique to maintain the snapshot's
point-in-time view of the file system
Snapshots can be created on demand to deliver a current,
consistent, online view of an active file system
20
ACFS Read-Only Snapshots
An enabler for:
On-line, disk-based, file backup model using snapshots and
individual file recoveries
21
ACFS Snapshots
The New Upgrade and Patching Strategy
23
Agenda
24
Storage Provisioning Pitfalls Pre 11.2
Reduces provisioning and planning for RAC
25
Storage Provisioning 11.2+
Simplified Storage Provisioning
New Way - Reduces
provisioning and
planning for RAC
Provision storage for
ASM Disks only
No need to nickel and
dime SAN Architects
for trivial space
Only manage ASM
Disks
ASM can now store:
OCR, Vote, ASM
Spfile, database home
All allocated from the
requested disk pool
26
Everything Inside ASM Model
27
Extending ASM to Manage ALL Data
29
Managing ASM
Which management interface should I use?
ASMCA (GUI)
Lightweight tool to create ASM Disk Groups, Volumes and ACFS
Command line option is available in silent mode
ASMCMD
Great for reports and listings
30
Storage Manageability - asmca
Even a caveman can do it !
31
ASM Configuration Assistant (ASMCA)
Recommended tool to configure ASM, Create ACFS file systems
Dynamic Volumes and ACFS
Ready for Oracle DB Home
Upgrade previous versions of ASM to the binaries to be installed
current version (11g R2)
Create & manage Dynamic Volumes
32
asmca Create Disk Group
1. Recommended to create
disk groups with asmca
2. Recommended AU in 11g
is 4MB
33
asmca Create ACFS for Database Home
Create a shared file system for Oracle Binary
34
Linux-Unix Extensions
Ease of Management
Mount an ACFS file system mount.acfs [-v] [-o options] device dir
# mount.acfs /dev/asm/vol1-123
/u01/oracle/acfsmounts
35
Extensions for asmcmd
36
Extensions for asmcmd
As a Privileged User life is easy
37
Enterprise Manager
Create Snapshot
1. Create
Snapshots
2. Delete
Snapshots
Manage up to
63 Snapshots
Command-line syntax
# /sbin/acfsutil snap create 11oct2009_db_1.before.patch
/apps/oracle/product/11.2.0/db_1acfsutil snap create:
Snapshot operation is complete.
39
Agenda
Brief ASM Overview
<Insert Picture Here>
Simplified Technology Stack
40
Rename Disk Group
Clone databases on same node or another node
41
Rename Disk Group
Recommended Method: Phase One followed by Phase Two
Phase Two Apply the config file generated from Phase One
# renamedg phase=two dgname=dg_prod_data newdgname=data2
config=rename_to_data2.conf verbose=true
Parsing parameters..
Parameters in effect:
Old DG name : DG_PROD_DATA
New DG name : DATA2
42
Agenda
Brief ASM Overview
<Insert Picture Here>
Simplified Technology Stack
43
Pre-11gR2 Installation
Install Clusterware
44
GI Tech Stack
Simplified Technology Stack only 2 Homes to manage
Database Home
i.e. /apps/oracle/product/11.2.0/db_1
Managed by DBAs
45
GI Tech Stack
Benefits of a Simplified Technology Stack
46
Grid Infrastructure Stack
Roles and Responsibilities
47
<Insert Picture Here>
49
ACFS Installation
50
Dynamic Volume Manager and
Dynamic Volumes
Provides volume management services and
OS standard disk device driver interface to ACFS
/dev/asm/vol1-123
Note: An AVD volume device may not be used as an OS boot or swap device, nor used as a root file system of the OS 51
ADVM Concepts
ADVM supports all storage solutions supported for ASM
except Exadata
Inherits and leverages underlying ASM redundancy
On Linux platforms Oracle ADVM volume devices are created
as block devices
Do not use raw (8) to map ADVM volume block devices into
raw volume devices.
All device management is performed against the ASM disks
underneath ADVM, so need to manage ADVM devices
Do not create multipathed devices over ADVM devices
Do not create ASMLIB devices on ADVM devices
Device partitioning (fdisk) not supported on ADVM
devices
52
Space Management with ACFS
53
ACFS Build Walk-through
Planning
Create a ASM diskgroup
Create a Shared DB Home Filesystem
Create local volume
Create a local filesystem
Create a ACFS snapshot
55
Build Walk-thru - Planning
A typical deployment work flow:
57
Build Walk-thru - Planning
Creation of ASM diskgroups, volumes, or filesystems
does not require root access
Mounting the filesystem will require root access.
58
ACFS ASM Deployment Practices
Two Disk Groups
DATA diskgroup -
Database datafiles
Oracle clusterware file (OCR and Voting Disk)
ACFS-ADVM volumes for:
ORACLE_HOME (Oracle binaries)
Oracle external files types
BFILEs
UTL_DIR
ETL data and external tables
59
ACFS ASM Deployment
Alternative
60
Build Walk-thru
ASMCMD
ASMCA
Shared Oracle Home
Non-db home (local filesystem)
61
ACFS-ADVM Build - ASMCMD
ASMCMD> lsdg
State Type Rebal Sector Block AU
Total_MB Free_MB Req_mir_free_MB Usable_file_MB
Offline_disks Voting_files Name
CONNECTED NORMAL N 512 4096 1048576
157479 151671 52493 49589
0 Y CRSDATA/
MOUNTED NORMAL N 512 4096 1048576
209972 176839 52493 62173
0 N DATA/
62
ACFS-ADVM Build - ASMCMD
$ asmcmd
ASMCMD [+] > volcreate -G DATA -s 5g ohdg1
ASMCMD [+] > volinfo -a
Diskgroup Name: DATA
Volume Name: OHDG1
Volume Device: /dev/asm/ohdg1-296
State: ENABLED
Size (MB): 5120
Resize Unit (MB): 256
Redundancy: UNPROT
Stripe Columns: 4
Stripe Width (K): 128
Usage:
Mountpath:
63
ACFS-ADVM Build - ASMCMD
$ ls -l /dev/asm/*
brwxrwx--- 1 root oinstall 252, 151553 Jun 30 12:40 /dev/asm/ohdg1-
296
# mkfs.acfs /dev/asm/ohdg1-296
mkfs.acfs /dev/asm/ohdg1-296
mkfs.acfs: version = 11.2.0.0.2.0
mkfs.acfs: on-disk version = 38.0
mkfs.acfs: volume = /dev/asm/ohdg1-296
mkfs.acfs: volume size = 5368709120
mkfs.acfs: Format complete.
# mkdir /u01/app/grid/product/11.2.0/db1
# mount /dev/asm/ohdg1-296 /u01/app/grid/product/11.2.0/db1
64
ACFS-ADVM Build - ASMCMD
ACFS resize - Walk-thru
65
ACFS-ADVM Build - ASMCMD
ACFS Snapshots - Walk-thru
$ acfsutil snap create oh_db_snap \
/u01/app/grid/product/11.2.0/db1
acfsutil snap create: Snapshot operation is
complete.
$ ls l /u01/app/grid/product/11.2.0/db1
/.ACFS/snaps]#
drwxrwxr-x 69 oracle oinstall 8192 Jan 5 00:23
oh_db_snap
66
ACFS-ADVM Build Walk Thru
using ASMCA
67
Create ASM Diskgroup
68
Create Shared DB Home contd
70
Shared DB Home Post-exec script
71
Create non-DB home volume
72
Verify Volume is created/enabled
73
Create filesystem over volume
YOUR DONE !!
75
ADVM-ACFS and Oracle Clusterware -
Startup
The ADVM-ACFS drivers are loaded
The CRS ASM agent will start the ASM instance
As part of ASM instance startup, disk groups will be
mounted
All ASM Dynamic volumes are enabled.
The OS ADVM volume device node in /dev is created
The CRS agent mounts any ACFS filesystems
The appropriate CRS agents will start their respective
resources.
RDBMS CRS agent will startup the database.
76
ADVM-ACFS and Oracle Clusterware -
Shutdown
The ACFS CRS agent will attempt to perform umounts for
filesystems on ASM volumes.
The pids of active processes using that filesystem will be
displayed and logged for sysadmin action
Eventually CRS shutdown will terminate active pids.
Shutting down the clusterware will stop ASM, thus shutting down
all ACFS file systems.
77
ASM 11gR2 How-Tos
http://www.dbaexpert.com/blog/category/asm/
78
79