1) SYSASM
Starting in Oracle Database 11g, a privilege called SYSASM is the primary means to access the ASM instance, and most administrative commands for ASM instances are deprecated for SYSDBA. SYSDBA is still available for backward compatibility, and if it is used, a warning message is written in the ASM alert log as follows
Warning: Deprecated privilege SYSDBA for command 'STARTUP'
The purpose of the SYSASM role is to provide a level of separation between the RDBMS and ASM credentials. The SYSASM role, which has full capability on the
ASM instance, is authenticated through the OSASM user group, similar to the SYSDBA role, which is authenticated through OSDBA. For Oracle Database 11g ASM, it is a best practice to use the SYSASM privilege instead of SYSDBA.
[oracle11@racnode1~]$ sqlplus "/ as sysasm"
To create the user ASMUSER, use the following command:
SQL> CREATE USER ASMUSER IDENTIFIED BY ASMUSER1;
SQL> GRANT SYSASM, SYSOPER TO ASMUSER;
To connect as ASMUSER:
[oracle@racnode1 ~]$ sqlplus "ASMUSER/ASMUSER as sysasm"
SQL> select * from v$pwfile_users;
USERNAME SYSDBA SYSOPER SYSASM
---------------------------- ----- ------- ----------------------------------------
SYS TRUE TRUE FALSE
ASMUSER FALSE TRUE TRUE
#######################################################################################
2) SYSOPER privilege reviewed
In Oracle ASM 10g, a user connecting as SYSOPER to an ASM instance has most of the same privileges’ as one connecting as SYSDBA, except for the ability to query V$ views.
Starting in Oracle Database 11g, the ASM SYSOPER privilege has responsibilities similar to those of a database SYSOPER. The following commands are available to SYSOPER users:
STARTUP/SHUTDOWN
ALTER DISKGROUP MOUNT/DISMOUNT
ALTER DISKGROUP ONLINE/OFFLINE DISK
ALTER DISKGROUP REBALANCE
ALTER DISKGROUP CHECK
All other commands––such as CREATE DISKGROUP, ADD/DROP/RESIZE DISK, and so on––require the SYSASM privilege and cannot be used with the
SYSOPER privilege.
#######################################################################################
3) V$ASM_ATTRIBUTE
This Oracle Database 11g view displays one row for each ASM attribute defined. These attributes are listed when they are defined in CREATE DISKGROUP or ALTER DISKGROUP statements. DISK_REPAIR_TIMER is an example of an attribute.
However, this view is not populated until
the diskgroup compatibility––that is, COMPATIBLE.ASM––is set to 11.1.0.
In Oracle Database 11g, the following attributes can be set:
COMPATIBLE.ASM
COMPATIBLE.RDBMS
DISK_REPAIR_TIME
AU_SIZE
#######################################################################################
4) Preferred Reads
Oracle Database 11g provides a feature called preferred reads.
This feature enables ASM administrators to specify a failure group for local reads–– that is, provide preferred reads. In a normal or high
redundancy diskgroup, when a secondary extent is on a preferred disk and the primary extent is remote, the secondary extent is read rather than the primary one on that node. This feature is especially beneficial for extended cluster configurations.
The ASM_PREFERRED_READ_FAILURE_GROUP initialization parameter is used to specify a list of failure group names that will provide local reads for each node in a cluster.
V$ASM_DISK indicates the preferred disks with a Y in the PREFERRED_READ column.
#######################################################################################
5) Fast Disk Resync
The Oracle Database 11g feature ASM Fast Disk Resync significantly reduces the time to recover from transient disk failures in failure groups.
In Oracle ASM Database 10g, disks that go offline because of disk failures are immediately dropped from the diskgroup. To reconstruct a disk’s contents, ASM
must add the disk back to the diskgroup and perform a full rebalance. This problem can be exacerbated if all disks in a failure group go offline.
With Fast Disk Resync, the repair time is proportional to the number of extents that have been written or modified since the failure. This feature can significantly
reduce the time that it takes to repair a failed diskgroup from hours to minutes.
The Fast Disk Resync feature allows the user a grace period to repair the failed disk and return it online. This time allotment is dictated by the ASM diskgroup
attribute DISK_REPAIR_TIME.
Fast Disk Resync requires that the COMPATIBLE.ASM and COMPATIBLE.RDBMS attributes of the ASM diskgroup be set to at least Oracle 11.1.0.0.
If the DISK_REPAIR_TIME parameter is not 0 and an ASM disk fails, that disk is taken offline but not dropped.
#######################################################################################
6) Variable Sized Extents
Each file stored in ASM requires metadata structures to describe the file extent locations. As the file grows, the metadata associated with that file also grows as well as the memory used to store the file extent locations. Oracle 11g introduces a new feature called Variable Sized Extents to minimize the overhead of the
metadata.
The database administrator (DBA) or ASM administrator need not manage variable extents; ASM handles this automatically.
For example, if a datafile is initially as small as 1GB, then the file extent size used will be 1 AU. As the file grows, several size thresholds are crossed and larger extent sizes are employed at each threshold, with maximum extent size capped at 64 AUs. Note that there are two thresholds: 20,000 extents (20GB with 1MB AUs) and 40,000 extents (40GB with 1MB AUs). Valid extent sizes are 1, 8, and 64 AUs (which translate to 1MB, 8MB, and 64MB with 1MB AUs).
The Variable Sized Extents feature is available only for diskgroups with Oracle 11g RDBMS and ASM compatibility. For diskgroups created with Oracle database 10g, the compatibility attribute must be advanced to 11.1.0. Variable extents take effect for newly created files, but will not be retroactively applied to files that were created with 10g software.
#######################################################################################
7) reading extent maps on demand
Oracle Database 11g significantly minimizes the file open latency issue by reading extent maps on demand. In Oracle 10g, for every file open, the complete
extent maps are built and sent to the RDBMS instance from the ASM instance. For large files, this unnecessarily lengthens file open time. In Oracle 11g, only the first 60 extents in the extent map are sent at file open time. The rest are sent in batches as required by the RDBMS.
#######################################################################################
8) new column in V$ASM_DISK called OS_MB
In Oracle Database 10g ASM, V$ASM_DISK shows the size of the disk when it was discovered by ASM; this size is reflected in the TOTAL_MB column. However, if the actual size of a disk is 250GB, but ASM uses (or allocates) only 200GB, you cannot determine the true disk size without querying the OS.
Starting in Oracle Database 11g ASM, a new column in V$ASM_DISK called OS_MB gives the actual OS size of the disk. This column can aid in appropriately
resizing the disk and prevent attempts to resize disks that cannot be resized.
For 10.2.0.3 and earlier, you need to restart all ASM instances to ensure that they see the new LUN size. Oracle Database 11g ASM can detect new LUN
sizes without restarting the instance. Issue ALTER DISKGROUP RESIZE DISK on one ASM instance.
#######################################################################################
9) Fast Rebalance (new diskgroup mount mode, called RESTRICTED)
In certain situations where the user does not need the diskgroup to be use accessible and needs rebalancing to complete as soon as possible, it is beneficial
to perform the rebalance operation without the extra overhead of the ASM to ASM and ASM to RDBMS messaging. In Oracle Database 11g, the Fast Rebalance feature eliminates this overhead by allowing a single ASM instance to rebalance the diskgroup without the messaging overhead. The primary goal of Fast Rebalance is to improve the overall performance of rebalance operation.
To eliminate messaging to other ASM instances, the ASM instance that performs the rebalance operation requires exclusive access to the diskgroup. To provide this exclusive diskgroup access, a new diskgroup mount mode, called RESTRICTED, was introduced in Oracle Database 11g. A diskgroup can be placed in RESTRICTED mode using STARTUP RESTRICT or ALTER DISKGROUP MOUNT RESTRICT. When a diskgroup is mounted in RESTRICTED mode, RDBMS instances are prevented from accessing that diskgroup and thus databases cannot be opened. Furthermore, only one ASM instance in a cluster can mount a diskgroup in RESTRICTED mode. At the end of the rebalance operation, the user must explicitly dismount the diskgroup and remount it in normal mode to make the diskgroup available to RDBMS instances.
#######################################################################################
#######################################################################################
#######################################################################################
#######################################################################################
#######################################################################################