Oracle, Technical

ASM Space Calculations and Hot Spares

This is quick and dirty. I hope to get a more polished write-up of what it means and how it works, but since I’m so busy right now I don’t know if I’ll get to it soon. In the meantime someone just might find this useful or informative so I’m just going to put it out there as it is.

This is an worked-through example of how ASM reports free space, taking into consideration “hot spare capacity” that is reserved to restore redundancy after the largest failure group dies.

ASM has 46 local disks attached to 6 controllers
- two controllers have 6 disks, other four have 8
- ASM has failure groups by controller


Each disk is partitioned. Get the size of the ASM partition according to 
the Linux kernel. All partitions are the same size.

# sfdisk -s /dev/sdav1

Now get the size info from ASM.

ASMCMD> lsdg
State    Type    Rebal  Sector  Block       AU  Total_MB   Free_MB  
MOUNTED  NORMAL  N         512   4096  1048576  18041706  18041326 
Req_mir_free_MB  Usable_file_MB  Offline_disks  Name
        3137688         7451819              0  DATA01/


-- size of individual disk in MB is kernel-reported KB divided by 1024
401624968 /1024 = 392211.8828125 M

-- ASM can't use partial AU's so truncate and we get Total_MB
392211 * 46 = 18041706

-- largest failure group [controller] has 8 disks so get Req_mir_free_MB
     (amount of "hot spare" capacity that is reserved to restore redundancy 
     after a controller failure)
392211 * 8 = 3137688

-- asm reports that some space is used; use "Free_MB" to see total free space
= 18041326

-- with normal-mirroring, usable space is (totalfree-spare)/2
(18041326 -  3137688) / 2 = 7451819

About Jeremy

Building and running reliable data platforms that scale and perform. about.me/jeremy_schneider



  1. Pingback: ASM Mirroring – No Hot Spare Disk : Ardent Performance Computing - July 16, 2010


This is my personal website. The views expressed here are mine alone and may not reflect the views of my employer.

contact: 312-725-9249 or schneider @ ardentperf.com




Enter your email address to receive notifications of new posts by email.

Join 56 other subscribers
%d bloggers like this: