|
* I/O bottle neckÀ» ã±â
a.
SQL> select phyrds,phywrts,d.name
2 from v$datafile d, v$filestat f
3 where d.file#=f.file#
4 order by d.name;
PHYRDS PHYWRTS NAME
---------- ---------- --------------------------------------------------
4 2 D:\ORACLE\ORADATA\IBM\DR01.DBF
4 2 D:\ORACLE\ORADATA\IBM\INDX01.DBF
18 16 D:\ORACLE\ORADATA\IBM\RBS01.DBF
1061 5 D:\ORACLE\ORADATA\IBM\SYSTEM01.DBF --> °¡Àå physical read°¡ ¸¹À½
4 2 D:\ORACLE\ORADATA\IBM\TEMP01.DBF
4 2 D:\ORACLE\ORADATA\IBM\TOOLS01.DBF
4 2 D:\ORACLE\ORADATA\IBM\USERS01.DBF
b. report.txt¿¡¼ ã±â
SQL> Rem I/O should be spread evenly accross drives. A big difference between
SQL> Rem phys_reads and phys_blks_rd implies table scans are going on.
SQL> select table_space, file_name,
2 phys_reads reads, phys_blks_rd blks_read, phys_rd_time read_time,
3 phys_writes writes, phys_blks_wr blks_wrt, phys_wrt_tim write_time,
4 megabytes_size megabytes,
5 round(decode(phys_blks_rd,0,0,phys_rd_time/phys_blks_rd),2) avg_rt,
6 round(decode(phys_reads,0,0,phys_blks_rd/phys_reads),2) "blocks/rd"
7 from stats$files order by table_space, file_name;
TABLE_SPACE FILE_NAME READS BLKS_READ ......------------ -------------------- ----- --------- ......
....
scott_data /disk2/scott_dat.dbf 61098 416752 .....
scott_index /disk2/scott_ind.dbf 0 0 ........
¿©±â¼ ÁÖÀÇÇØ¾ß ÇÒÁ¡Àº data¿¡¼´Â I/O °¡ Å©³ª index¿¡¼´Â ¾ø´Â°ÍÀº index°¡ Àß »ç¿ëµÇÁö ¾Ê°Å³ª
ÇÊ¿äÇÑ index°¡ ºÎÁ·Çϴٴ°ÍÀ» ³ªÅ¸³¿
|