ASM Provides Striping and Mirroring.: 1. What Is The Use of ASM (Or) Why Is ASM Preferred Over File System?

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 4

1.

What is the use of ASM (or) Why is ASM preferred over file system?

ASM provides striping and mirroring.


a) Provides automatic load balancing over all the available disks, thus reducing hot spots in
the file system.
b) Prevents fragmentation of disks, so you don’t need to manually relocate data to tune I/O
performance.
c) Adding disks is straightforward – ASM automatically performs online disk reorganization
when you add or remove storage.
d) Uses redundancy features available in intelligent storage arrays.
e) The storage system can store all types of database files.
f) Using disk groups makes configuration easier, as files are placed into disk groups.
How ASM interacts with database?
First time, when rdbms instance tries to access an asm file, It needs to establish a local asm
connection.
ASMB process contacts CSS using diskgroup names and gets the connection string. Using
that connection string, bequeath connection is established between asm and RDBMS
instance.
The RDBMS authenticates itself to the ASM instance via operating system (OS)
authentication by connecting as SYSDBA. This initial connection between the ASM instance
and the RDBMS instance is known as the umbilicus, and remains active as long as the
RDBMS instance has any ASM files open.
ASMB is the rdbms side process and UFG(umbilicus foreground process) is the asm side
process. Both communciate through this umbilicus.
When ASM instance opens a datafile, ASM ships the  file’s extent map to rdbms instance ,
where it is stored in SGA.
By using that extent map , rdbms can do i/o on the asm files directly without going through
asm instance

1. What is striping in ASM.

ASM striping is the process of dividing a file into 1 MB extents and spreading the extents
evenly across all disks in the disk group

Oracle ASM striping has two primary purposes:

· To balance loads across all of the disks in a disk group


· To reduce I/O latency

2. What mirroring in ASM.

ASM provides automatic mirroring of ASM files and allows the mirroring level to be
specified by group. This mirroring occurs at the extent level. If a disk group is mirrored, each
extent has one or more mirrored copies, and mirrored copies are always kept on different
disks in the disk group.
There are three ASM mirroring options:
Normal redundancy (Two-way mirroring) - Each extent has one mirrored copy in this option
High redundancy (Three-way mirroring) - Each extent has two mirrored copies in this option.
External redundancy(Unprotected mirroring) - ASM provides no mirroring in this option,
which is used when mirroring is provided by the disk subsystem.
3. Where ASM pfile will be stored?

ASM pfile normally will be located in GRID_HOME/dbs and it contains location of spfile
which in ASM disk groups.

5. What are the files we can store in ASM?

we can store CRD files, archivelog files, spfile, rman backup files, flashback logs in ASM

6. What is rebalancing and when it happens.

re-balancing is process of striping, when ever disk is added or removed to ASM diskgroup
asm will start rebalancing data accross all disks. if you add disk, rebalancing will take some
data from all the disks and store into new disk so that all disks in ASM diskgroup will fill
equally.

7. What is power limit and its range from version 11.2.0.4

Beginning with Oracle Database 11g Release 2(11.2.0.2), if the COMPATIBLE.ASM disk


group attribute is set to 11.2.0.2 or higher, then the range of values is 0 to 1024.

8. How can we know ASM re-balance is going on in ASM instance.

We can use V$ASM_OPERATION view to check re-balance is going on or not. if below


query displays any rows, we can say re-balance is in progress. 

select * from V$ASM_OPERATION where STATE='RUN';

9. Can we copy files from ASM to OS file system.

 Yes, we can copy files from ASM using cp commands in ASMCMD command prompt.

12. What is Req_mir_free_MB in lsdg output?


13. How to take ASM metadata backup?

2. What are the init parameters related to ASM?


Answer:
INSTANCE_TYPE = ASM
ASM_POWER_LIMIT = 11
ASM_DISKSTRING = '/dev/rdsk/*s2', '/dev/rdsk/c1*'
ASM_DISKGROUPS = DG_DATA, DG_FRA
3. What is rebalancing (or) what is the use of ASM_POWER_LIMIT?
Answer:
ASM_POWER_LIMIT is a dynamic parameter, which will be useful for rebalancing the data
across disks.
Value can be 1(lowest) to 11 (highest).
4. What are the different types of redundancies in ASM & explain?
Answer:

 Normal redundancy - for 2-way mirroring, requiring two failure groups, when ASM
allocates an extent for a normal redundancy file, ASM allocates a primary copy and a
secondary copy. ASM chooses the disk on which to store the secondary copy in a different
failure group other than the primary copy.
 High redundancy - for 3-way mirroring, requiring three failure groups, in this case,
the extent is mirrored across 3 disks.
 External redundancy - to not use ASM mirroring. This is used if you are using
hardware mirroring or third-party redundancy mechanisms like RAID, Storage arrays.
5. When you will use external redundancy and what are the advantages of it?
Answer :

6. How to copy files to/from ASM from/to filesystem?


Answer :
By using ASMCMD cp command

7. How to find out the databases, which are using the ASM instance?
Answer :
ASMCMD> lsct
SQL> select DB_NAME from V$ASM_CLIENT;

8. What are the different types of stripings in ASM & their differences?
Answer:
Fine-grained striping
Coarse-grained striping

9. What happens if you miss "+" sign while adding datafile in ASM diskgroup ?
Answer :

10. What is the allocation unit and what is the default value of au_size and how to change it?
Answer:
Every ASM disk is divided into allocation units (AU). An AU is the fundamental unit of
allocation within a disk group. A file extent consists of one or more AU. An ASM file
consists of one or more file extents.
CREATE DISKGROUP disk_group_2 EXTERNAL REDUNDANCY DISK '/dev/sde1'
ATRRIBUTE 'au_size' = '32M';
lsdg
select NAME,ALLOCATION_UNIT_SIZE from v$asm_diskgroup;
11. What are the background processes in ASM?
Answer:

 ASMB - This ASMB process is used to provide information to and from cluster
synchronization services used by ASM to manage the disk resources. It's also used to update
statistics and provide a heartbeat mechanism.
 RBAL, Re-Balance - RBAL is the ASM related process that performs rebalancing of
disk resources controlled by ASM.
 ARBx, Actual Rebalance - ARBx is configured by ASM_POWER_LIMIT, a slave
for rebalancing operations.

12. What processes does the rebalancing?


Answer:
RBAL, ARBx

13. How to dismount the ASM disk group from a particular instance in RAC?
Answer :

14. How to add/remove disk to/from diskgroup?

Answer:
ALTER DISKGROUP data1 ADD DISK '/devices/diska5';
ALTER DISKGROUP disk_group_1 DROP DISK diska2;

What is the ASM instance in Oracle?

You might also like