Skip to content

Gvasmdsk (gvasmdsk.sql)

This script monitors ASM disk I/O performance, calculating average read and write times per operation and tracking I/O errors. Essential for identifying slow disks and potential hardware issues in ASM environments.

rem gvasmdsk.sql
rem
set linesize 300
set pagesize 200
rem
ttitle 'ASM Disk Perf. Info'
rem
col GROUP_NUMBER format 999 heading 'GRP|NBR'
col DISK_NUMBER format 999 heading 'DSK|NBR'
col PATH format a35 heading 'Path'
col READS format 999,999,999
col READ_TIME format 999,999,999.99 heading 'Read Time|Hundreths of Sec'
col READ_ERRS format 999,999 heading 'READ|ERR'
col WRITES format 999,999,999
col WRITE_TIME format 999,999,999.99 heading 'Write Time|Hundreths of Sec'
col WRITE_ERRS format 999,999 heading 'WRITE|ERR'
select GROUP_NUMBER
,DISK_NUMBER
,PATH
,READS
,READ_TIME/READS READ_TIME
,READ_ERRS
,WRITES
,WRITE_TIME/WRITES WRITE_TIME
,WRITE_ERRS
from gv$asm_disk
where reads is not null
or writes is not null
order by group_number
,disk_number
;

The script prompts for:

  • None - this script requires no parameters## Usage
-- Basic usage
@gvasmdsk.sql
ASM Disk Perf. Info
GRP DSK Read Time Write Time
NBR NBR Path READS Hundreths of Sec READ WRITES Hundreths of Sec WRITE
--- --- ----------------------------------- ------------ ---------------- ------- ------------ ---------------- -------
1 0 /dev/raw/raw1 1,234,567 0.85 0 2,345,678 1.25 0
1 1 /dev/raw/raw2 1,345,678 0.92 0 2,456,789 1.18 0
1 2 /dev/raw/raw3 1,123,456 1.35 2 2,234,567 1.45 1
1 3 /dev/raw/raw4 1,234,567 0.88 0 2,345,678 1.22 0
2 0 /dev/raw/raw5 987,654 0.75 0 1,876,543 1.05 0
2 1 /dev/raw/raw6 876,543 0.78 0 1,765,432 1.08 0
2 2 /dev/raw/raw7 923,456 12.50 5 1,823,456 15.25 8
2 3 /dev/raw/raw8 891,234 0.82 0 1,789,012 1.12 0
3 0 /dev/raw/raw9 567,890 0.65 0 654,321 0.95 0
3 1 /dev/raw/raw10 578,901 0.68 0 665,432 0.98 0