Sundaramurthy Blog

February 2, 2010

ASM disk space

Filed under: ASM,ASM Commands — sundar5 @ 11:56 pm
SET LINESIZE  174
SET PAGESIZE  9999
SET VERIFY    off
COLUMN disk_group_name        FORMAT a20           HEAD ‘Disk Group Name’
COLUMN disk_file_path         FORMAT a17           HEAD ‘Path’
COLUMN disk_file_name         FORMAT a20           HEAD ‘File Name’
COLUMN disk_file_fail_group   FORMAT a20           HEAD ‘Fail Group’
COLUMN total_mb               FORMAT 999,999,999   HEAD ‘File Size (MB)’
COLUMN used_mb                FORMAT 999,999,999   HEAD ‘Used Size (MB)’
COLUMN pct_used               FORMAT 999.99        HEAD ‘Pct. Used’
break on report on disk_group_name skip 1
compute sum label “”              of total_mb used_mb on disk_group_name
compute sum label “Grand Total: ” of total_mb used_mb on report
SELECT
NVL(a.name, ‘[CANDIDATE]’)                       disk_group_name
, b.path                                           disk_file_path
, b.name                                           disk_file_name
, b.failgroup                                      disk_file_fail_group
, b.total_mb                                       total_mb
, (b.total_mb – b.free_mb)                         used_mb
, ROUND((1- (b.free_mb / b.total_mb))*100, 2)      pct_used
FROM
v$asm_diskgroup a RIGHT OUTER JOIN v$asm_disk b USING (group_number)
ORDER BY
a.name
/
Disk Group Name Path File Name   Fail Group File Size (MB) Used Size (MB) Pct. Used
--------------------- ----------- ------------------------ -------------- ---------
ARCLOG
 ORCL:DISK305      DISK305     DISK305          409,600         24,672      6.02
 ORCL:DISK301      DISK301     DISK301          409,600         24,704      6.03
 ORCL:DISK300      DISK300     DISK300          409,600         24,976      6.10
 ORCL:DISK303      DISK303     DISK303          409,600         24,720      6.04
 ORCL:DISK304      DISK304     DISK304          409,600         24,432      5.96
 ORCL:DISK302      DISK302     DISK302          409,600         24,608      6.01
****************                         -------------- --------------
                                              2,457,600        148,112
DATA
 ORCL:DISK0        DISK0       DISK0          1,502,256      1,144,928     76.21
 ORCL:DISK10       DISK10      DISK10         1,502,256      1,148,080     76.42
 ORCL:DISK100      DISK100     DISK100        1,502,256      1,141,792     76.01
 ORCL:DISK101      DISK101     DISK101        1,502,256      1,143,216     76.10
 ORCL:DISK102      DISK102     DISK102        1,502,256      1,144,032     76.15
 ORCL:DISK103      DISK103     DISK103        1,502,256      1,145,232     76.23
 ORCL:DISK2        DISK2       DISK2          1,502,256      1,141,424     75.98
 ORCL:DISK20       DISK20      DISK20         1,502,256      1,143,504     76.12
 ORCL:DISK200      DISK200     DISK200        1,502,256      1,145,952     76.28
 ORCL:DISK201      DISK201     DISK201        1,502,256      1,145,776     76.27
****************                         -------------- --------------
                                            189,284,256    144,091,456
TEMP
 ORCL:DISK93       DISK93      DISK93         1,502,256      1,335,488     88.90
 ORCL:DISK5        DISK5       DISK5          1,502,256      1,335,216     88.88
 ORCL:DISK49       DISK49      DISK49         1,502,256      1,334,432     88.83
 ORCL:DISK82       DISK82      DISK82         1,502,256      1,334,960     88.86
 ORCL:DISK79       DISK79      DISK79         1,502,256      1,335,248     88.88
 ORCL:DISK7        DISK7       DISK7          1,502,256      1,334,928     88.86
 ORCL:DISK6        DISK6       DISK6          1,502,256      1,335,456     88.90
****************                         -------------- --------------
                                             36,054,144     32,039,856
[CANDIDATE]
 ORCL:DISK311                                 1,502,267      1,502,267    100.00
 ORCL:DISK310                                 1,502,267      1,502,267    100.00
 ORCL:DISK309                                 1,502,267      1,502,267    100.00
 ORCL:DISK308                                 1,502,267      1,502,267    100.00
 ORCL:DISK307                                 1,502,267      1,502,267    100.00
 ORCL:DISK306                                 1,502,267      1,502,267    100.00
****************                         -------------- --------------
                                              9,013,602      9,013,602
                                         -------------- --------------
Grand Total:                                236,809,602    185,293,026
162 rows selected.
Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: