Allocation Unit and Extents In ASM

ASM was introduced with Oracle 10g and is used as a Volume Manager and a file system. It provides both mirroring and striping of the database files. To use ASM you need to create a Diskgroup and add disks/raw devices to the Diskgroup.Data is allocated in disks in terms of Extents. As per documentation

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.

In case of 10g,ASM divides files into 1 MB extents/AU’s and spreads each file’s extents evenly across all disks in the disk group.

Starting from 11g, we can create Diskgroups of varying AU sizes ranging from 1 MB to 64 MB in powers of two, such as, 1, 2, 4, 8, 16, 32, or 64. Each Allocation Unit consumes some amount of memory in ASM SGA for storing the metadata information. Very Large Databases (VLDB) which can have sizes in TeraBytes will have too many AU’s allocated and also memory requirement for ASM instance will also increase. This will also impact the performance of the application. As a result Variable Size extents concept has been introduced in 11g.

Extents and Allocation Units

Number of Extents Size
0 – 19999 1*AU
20000 – 39999 8*AU
40000 – 59999 64*AU

As shown in table, for first 20000 extents Extent size is always equal to AU. This keeps on increasing gradually.

The ASM coarse striping is always equal to the disk group AU size, but fine striping size always remains 128KB in any configuration . The AU size is determined at creation time with the allocation unit size (AU_SIZE>) disk group attribute. The values can be 1, 2, 4, 8, 16, 32, and 64 MB.



Now all this is documented and if I do not mention anything else you will be angry at me 🙂

Now we know this is implemented from 11g. But does that mean it is not available in 10g??

No. It is available in 10g, but we need to play around with some Hidden Parameters.

Warning – You should try this out in Development Environment before trying in Production database. Also contact Oracle Support to validate if this can be implemented in your system and ensure that there are no reported issues/bugs.

<span style="color: #000099;"><span style="color: #3333ff;">SQL&gt; select nam.ksppinm NAME, val.KSPPSTVL VALUE from x$ksppi nam, x$ksppsv val where nam.indx = val.indx and nam.ksppinm like '%asm%';</span></span>

<span style="color: #000099;"><span style="color: #3333ff;">NAME                           VALUE
------------------------------ --------------------
asm_diskstring                 /dev/sda7*
_asm_disk_repair_time          14400
asm_diskgroups                 DATA
asm_power_limit                1
<strong>_asm_ausize                    1048576</strong>
_asm_blksize                   4096
_asm_acd_chunks                1
_asm_libraries                 ufs
_asm_maxio                     1048576
_asm_allow_only_raw_disks      TRUE
_asmlib_test                   0
_asm_allow_resilver_corruption FALSE
_asmsid                        asm
_asm_wait_time                 18
_asm_skip_resize_check         FALSE
_asm_stripewidth               8
<strong>_asm_stripesize                131072</strong>
_asm_droptimeout               60
_asm_emulmax                   10000
_asm_emultimeout               0
_asm_kfdpevent                 0</span>

We need to look at parameters _asm_ausize and _asm_stripesize which are set to 1 M and 128 K respectively.

In case you wish to create Diskgroup of say 10M Allocation Unit and want to increase the Stripe size to 1M,then set following parameter in pfile

<span style="color: #ff0000;"><strong>_asm_ausize=</strong></span><span style="color: #ff0000;"><strong>10485760
</strong></span><span style="color: #ff0000;"><strong>_asm_stripesize=</strong></span><span style="color: #ff0000;"><strong>1048576</strong></span>

Restart the ASM instance. Please note that these settings will be applicable only for new Diskgroups and will not modify the existing Diskgroups.

You will be required to change the template for the Diskgroup else all the datafiles will use COARSE attribute and will have stripe of 10M. You can find details in 10g SQL reference Guide

Tags: , , ,

8 thoughts on “Allocation Unit and Extents In ASM”

  • I would say one of the benefits of both larger AU size and indeed variable sized extents was to reduce the amount of SGA in the RDBMS instance that is utilised for keeping the extent maps!


  • As mentioned earlier , benefit of increased Au size is that it reduces the memory required for ASM Metadata.
    I have seen database configuration using 16 Mb Allocation unit with 1 Mb stripe size . I believe you can use AU size of 64 Mb with stripe size of 1-2 M as you seem to be working with data warehouse and is likely to grow to larger size.

  • Patrick,

    You need to set _asm_stripesize=1048576 parameter in spfile/pfile to change the stripe size. As mentioned these settings will be valid for new diskgroups and not existing diskgroups. You will also be required to change the templates for datafiles to incorporate this new stripe size definiton.

    Please note that you cannot change the setting for existing diskgroups.

  • Hi Amit,

    Thanks for the reply. I just have 1 more question.
    As you mentioned above “The ASM coarse striping is always equal to the disk group AU size, but fine striping size always remains 128KB in any configuration.”

    If i have 64M AU, does that mean for the fine stripe, the AU will stripe across all available disks in the diskgroup with the size 0f 128K?


  • Yes, stripe size will remain as 128k unless you change the _asm_stripesize. Also as mentioned earlier, it would make sense to change the datafile template to fine instead of coarse. You can use following command to do the same for datafile template

  • HI,
    i am newbie….

    please guide me!

    My manager asked me to configure ASM in 11g with single instance database!
    with Normal redundancy with two disks as one disgroup(mirror)
    he asked me two copies of data wil be there in two disks respectively…
    he wants to write data to one disk and read data from one disk and he suggested me that…. using preferred Mirror Read 11g we can achieve this!

    guide me…is there any document for this….

    please ……..

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.