Professional Documents
Culture Documents
Management
(ASM)
Speaker Introduction
Michael Messina
Oracle ACE
Mike.Messina@roltasolutions.com
www.tusc.com / www.roltasolutions.com
Contents
Overview
ASM Structure / Components
Benefits of ASM
Any Issues?
Infrastructure
Storage Options
Redundancy
External, Normal, High
Multiple Paths to Storage
Database Storage
File Storage (ASM Clustered File System)
Contents
Volume Management
Requirements
ASMLib for Linux
Create disks for ASM
Contents
Installing ASM
Contents
Discovering Disks
Mounting/Un-mounting Disk Groups
Create ASM Disk Groups
Add Disk/Space to ASM Disk Group
Remove Disk/Space from ASM Disk Group
Change ASM Disk Group Compatibility
Rename Disk Group
Managing ASM File Access Control for Disk Groups
Drop ASM Disk Group
Contents
Overview
AUTOMATIC STORAGE
MANAGEMENT (ASM)
Overview
ASM Instance
ASM Disks
ASM Files
Control files
Data files, temporary data files, and data file copies
SPFILEs
Online redo logs, archive logs, and Flashback logs
RMAN backups
Disaster recovery configurations
Change tracking bitmaps
Data Pump dumpsets
Benefits of ASM
ASM can support storage for multiple Databases and Database Versions
Any Issues?
For Normal or High Redundancy Disk Groups the disk for the failgroup(s)
are required when the disk group is created.
ASM does not provide any power management features, all power
management features are controlled outside the ASM technology stack.
INFRASTRUCTURE
Storage Options
Redundancy
External
Normal
High
Redundancy
Multipathing
Database Storage
11gR2 added the capability for ASM to act as a file system for
all operating system files with ACFS
VOLUME MANAGEMENT
Fail Groups
DataGuard
Requirements
Check Installation
Install ASMLib
http://www.oracle.com/technology/software/tech/linux/asmlib/rhel5.html
rpm -i oracleasm-support-2.1.3-1.el5.i386.rpm
rpm -i oracleasm-2.6.18-128.1.6.el5-2.0.5-1.el5.i686.rpm
rpm -i oracleasmlib-2.0.4-1.el5.i386.rpm
rpm -i oracleasm-2.6.18-128.1.6.el5debug-2.0.5-1.el5.i686.rpm
rpm -i oracleasm-2.6.18-128.1.6.el5-debuginfo-2.0.5-1.el5.i686.rpm
rpm -i oracleasm-2.6.18-128.1.6.el5PAE-2.0.5-1.el5.i686.rpm
rpm -i oracleasm-2.6.18-128.1.6.el5xen-2.0.5-1.el5.i686.rpm
Configure ASMLib
/etc/init.d/oracleasm configure
fdisk /dev/sda
INSTALLING ASM
hard nproc
hard nofile
16384
65536
Ensure that the limits are configured to set for new sessions by
ensuring the following are in the /etc/pam.d/system-auth file.
session required pam_limits.so
session required pam_unix.so
Ensure that the following are included in the .bash_profile for the
oracle user
ulimit -n 65536
ulimit -u 16384
kernel.msgmnb = 65536
kernel.msgmax = 65536
kernel.shmmax = 4294967295
kernel.shmall = 268435456
kernel.sem=250 32000 100 128
net.ipv4.ip_local_port_range = 1024 65000 < 11gR1
net.ipv4.ip_local_port_range = 9000 65500 >= 11gR2
net.core.rmem_default=4194304
net.core.wmem_default=262144
net.core.rmem_max=4194304
net.core.wmem_max=1048576
fs.file-max = 6815744
fs.aio-max-nr = 1048576
September 12 / Slide 34 / Title of Document
CD3
rpm -Uvh libaio-0
rpm -Uvh libaio-devel-0.3.105-2.i386.rpm
CD4
rpm -Uvh elfutils-libelf-0
rpm -Uvh elfutils-libelf-devel-0.91.1-3.i386.rpm
CD1
rpm -Uvh unixODBC-2.2.11-1.RHEL4.1.i386.rpm
Installation Basics
<GRIDHOME>/bin/asmcmd
ASMCMD Commands
Instance Management
iostat
lsct
lsop
ASMCMD Commands
File Access
chgrp
chmod
chown
groups
grpmod
lsgrp
lsusr
mkgrp
mkusr
passwd
rmgrp
rmusr
ASMCMD Commands
File Management
cd
du
find
ls
lsof
mkalias
mkdir
pwd
rm
rmalias
ASMCMD Commands
chdg
Changes a disk group (add, drop, or rebalance).
chkdg
Checks or repairs a disk or failure group.
cp
Enables you to copy files between ASM disk groups on a
local instance and remote instances.
dgdrop
Drops a disk group.
lsattr
Lists the attribute and attribute settings of a disk group.
lsdg
Lists disk groups and their information.
lsdsk
Lists disks visible to ASM.
lsgrp
Lists ASM access control list (ACL) groups.
md_backup Creates a backup of all of the mounted disk groups.
md_restore Restores disk groups from a backup.
mkdg
Creates a disk group.
mount
Mounts a disk group.
ASMCMD Commands
offline
online
rebal
remap
setattr
umount
ASMCMD Commands
volcreate
voldelete
voldisable
volenable
volinfo
volresize
volset
volstat
Create a volume
Delete a volume
Disable a volume.
Enable a Volume
Volume Information,
Resize a volume
Change existing attribute
Report volume I/O statistics.
Discovering Disks
You can discover disk groups using ASM lib or the ASM
instance.
ASMLib
/etc/init.d/oracleasm scandisks
/etc/init.d/oracleasm listdisks
ASM Instance
External Redundancy
SQL Plus
asmcmd
Create diskgroup_config.xml
<dg name="dgroup1" redundancy=external">
<dsk string="/dev/raw/disk1" />
<a name="compatible.asm" value="11.2"/>
<a name="compatible.rdbms" value="11.2"/>
</dg>
ASMCMD> mkdg diskgroup_config.xml
Normal Redundancy
SQL Plus
asmcmd
Create diskgroup_config.xml
<dg name="dgroup1" redundancy="normal">
<fg name="fg1">
<dsk string="/dev/raw/disk1" />
<dsk string="/dev/raw/disk2" />
</fg>
<fg name="fg2">
<dsk string="/dev/raw/disk3" />
<dsk string="/dev/raw/disk4" />
</fg>
<a name="compatible.asm" value="11.2"/>
<a name="compatible.rdbms" value="11.2"/>
</dg>
High Redundancy
SQL Plus
asmcmd
Create diskgroup_config.xml
Mount
SQL Plus
asmcmd
Un-mount
SQL Plus
asmcmd
SQL Plus
SQL Plus
COMPATIBLE.RDBMS
ASM Instance
RDBMS Instance
10.1
10.1
>=10.1
>=10.1
11.1
10.1
>=11.1
>=10.1
11.2
11.1
>=11.2
>=11.1
11.2
11.2
>=11.2
>=11.2
SQL Plus
asmcmd
mkusr
mkgrp
rmgrp
rmusr
chown
chgrp
chmod
-a Add User
-d Remove User
chown
chgrp
chmod
SQL Plus
DROP DISKGROUP dg1 ;
** If Disk Group has files then use the INCLUDING CONTENTS clause
SQL> DROP DISKGROUP disk_group_1 INCLUDING CONTENTS;
asmcmd
asmcmd> dgdrop dg1 ;
** If Disk Group has files then use the r option
asmcmd> dgdrop r dg1 ;
Overview
ACFS executes as a UNIX (POSIX and X/OPEN compatible) file system for
Linux and UNIX and ACFS works as a Windows Filesystem on Windows.
Oracle ACFS are provided with single node file system coherency for
single host or when distributed across cluster members.
Oracle ACFS file system can be used for an Oracle Database Home file
system.
Hierarchical filesystem
Tree-structured Namespace
Files
Sub-directories
Files are the leaf nodes
Single-filesystem naming model
Must first have a Disk Group for the ACFS file system to use
volinfo a dg1
Thank You
Thank you!