ttitle skip center 'Database File IO Weight' skip center -
'Order by Drive' skip 2
column total_io format 999999999999999
column weight format 999.99
column File_name format a40
break on Drive skip 2
compute sum of weight on drive
select substr(DF.Name,1,6) drive,
DF.Name File_name,
FS.phyblkrd+FS.Phyblkwrt total_io,
100*(FS.phyblkrd+FS.Phyblkwrt)/MaxIO weight
from v$filestat FS , v$datafile DF,
(select max(phyblkrd+phyblkwrt) MaxIO
from v$filestat)
whereDF.FILE# = FS.FILE#
order by drive, weight desc
spool /tmp/io_weight
/
spool off
exit;
与有志考OCP的朋友分享。 |