Oracle waits event:DB File Sequential Read
The DB File Sequential Read wait event generally indicates a single block read (an index read,
for example). A large number could indicate poor joining orders of tables or unselective indexing.
This number will certainly be large (normally) for a high-transaction, well-tuned system. You
should correlate this wait with other known issues within the STATSPACK report such as
inefficient SQL. Check to ensure index scans are necessary and check join orders for multiple
table joins. The DB_CACHE_SIZE will also be a determining factor in how often these waits show
up; hash-area joins causing problems should show up in the PGA memory but similarly are
memory hogs that can cause high wait numbers for sequential reads or can also show up as
direct path read/write waits. Range scans can read a lot of blocks if the data is spread in many
different blocks (density within blocks could cause issues with range scans, and reverse key
indexes could be problematic with range scans). Loading data in a sorted manner can help
range scans and reduce the number of blocks read. Partitioning can help, as it can eliminate
some blocks. Look for unselective indexes that are causing a lot of these. Locate the data on
disk systems that either have more disk caching and/or are buffered by OS file system cache.
Correlated to the waits are the values for P1,P2,P3=file, block, blocks.
Ïà¹ØÎĵµ£º
Èý¡¢ PL/SQL³ÌÐòµ¥Ôª
1¡¢ÎÞÂÛÊǵ¥¶ÀµÄ¹ý³Ì/º¯Êý£¬»¹ÊǰüÖеĹý³Ì/º¯Êý£¬¶¼Í³³ÆÎª×Ó³ÌÐò¡£
2¡¢¹ý³Ì
1) Òì³£´¦Àí²¿·ÖÊÇ¿ÉÑ¡µÄ¡£
2) ¹ý³ÌÃûÓ¦¸ÃÓö¯´Ê£¬ÒòΪ¹ý³Ìͨ³£ÊÇÖ´ÐÐijÖÖ¶¯×÷¡£¹ý³Ì²¢²»Ò»¶¨¾ßÓвÎÊý¡£µ±´ ......
¡¡¡¡ ÎÒÃÇ¿ÉÒÔͨ¹ýÏÂÃæµÄÓï¾äÀ´²éѯÊý¾Ý¿âµÄĬÈÏÁÙʱ±í¿Õ¼ä£º
¡¡¡¡
¡¡¡¡SQL> select * from database_properties where property_name = 'DEFAULT_TEMP_TABLESPACE'£»
¡¡¡¡¡¡
¡¡¡¡ ĬÈÏÁÙʱ±í¿Õ¼äµÄÏÞÖÆ£º
¡¡¡¡
¡¡¡¡1. ĬÈÏÁÙʱ±í¿Õ¼ä±ØÐëÊÇTEMPORARYµÄ:
¡¡¡¡
¡¡¡¡SQL> alter database default temporary t ......
Oracle µÄÉú²ú¿â¶¼ÊÇÆô¶¯Ôڹ鵵ģʽÏ£¬RACϹ鵵·Ç¹éµµµÄÇл»ºÍµ¥ÊµÀýÒ²ÊÇÒ»ÑùµÄ£¬¶¼ÊÇÔÚMOUNTģʽÏÂÖ´ÐÐALTER DATABASE ARCHIVELOG/NOARCHIVELOG;ÃüÁî¡£ ²»Í¬µÄÊÇ£ºRAC»·¾³ÏÂËùÓÐʵÀý¶¼±ØÐë´¦ÓÚ·ÇOPEN״̬£¬È»ºóÔÚÈÎÒâÒ»¸ö´¦ÓÚMOUNT״̬µÄʵÀýÖ´ÐÐALTER DATABASEÃüÁ²Ù×÷³É¹¦ºó£¬ÔÙÕý³£Æô¶¯ ......
--ÈçºÎÓÃgrade±íµÄ×ÊÁÏÈ¥¸üÐÂusertable±íµÄ×ÊÁÏ£¨ÓйØÁªµÄ×Ö¶Îuserid£©
update usertable u set u.grade =
(select g.grade from grade g where g.userid = u.userid);
--ÈçºÎʹ²éѯ½á¹û×Ö¶ÎÉú³ÉÐòºÅ
select rownum, t.* from sm_t_pad_new t
--ÈçºÎ¿ìËÙ×öÒ»¸öºÍÔ±íÒ»ÑùµÄ±¸·Ý±í
create ......