Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB
ÈÈÃűêÇ©£º c c# c++ asp asp.net linux php jsp java vb Python Ruby mysql sql access Sqlite sqlserver delphi javascript Oracle ajax wap mssql html css flash flex dreamweaver xml
 ×îÐÂÎÄÕ :

Oracle Waits event:DB File Scattered Read

The DB File Scattered Read wait event generally indicates waits related to full table scans or fast
full index scans. As full table scans are pulled into memory, they are scattered throughout the
buffer cache, since it is usually unlikely that they fall into contiguous buffers. A large number
indicates that there may be missing or suppressed indexes. This could also be preferred, since it
may be more efficient to perform a full table scan than an index scan. Check to ensure full table
scans are necessary when you see these waits. Try to cache small tables to avoid reading them
into memory over and over again. Locate the data on disk systems that have either more disk
caching or are buffered by the OS file system cache. DB_FILE_MULTIBLOCK_READ_COUNT
can make full scans faster (but it could also influence Oracle to do more of them). You can also
partition tables and indexes so that only a portion is scanned. Slow File I/O (slow disks) can
......

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 pro ......

oracle raw devices

1.LVM:
[root@vmfs ~]# pvdisplay
  --- Physical volume ---
  PV Name               /dev/sdg
  VG Name               db_v4
  PV Size               2.00 GB / not usable 0  
  Allocatable           yes
  PE Size (KByte)       4096
  Total PE              511
  Free PE               1
  Allocated PE          510
  PV UUID               MlB8lE-H3DL-RCcf-p5Di-J6A2-INLc-zw328m
   ......

ORACLE ×óÓÒÁ´½Ó

Êý¾Ý±íµÄÁ¬½ÓÓÐ:
1¡¢ÄÚÁ¬½Ó(×ÔÈ»Á¬½Ó): Ö»ÓÐÁ½¸ö±íÏàÆ¥ÅäµÄÐвÅÄÜÔÚ½á¹û¼¯ÖгöÏÖ
2¡¢ÍâÁ¬½Ó: °üÀ¨
     £¨1£©×óÍâÁ¬½Ó(×ó±ßµÄ±í²»¼ÓÏÞÖÆ)
     £¨2£©ÓÒÍâÁ¬½Ó(ÓÒ±ßµÄ±í²»¼ÓÏÞÖÆ)
     £¨3£©È«ÍâÁ¬½Ó(×óÓÒÁ½±í¶¼²»¼ÓÏÞÖÆ)
3¡¢×ÔÁ¬½Ó(Á¬½Ó·¢ÉúÔÚÒ»ÕÅ»ù±íÄÚ)
select a.studentno, a.studentname, b.classname
      from students a, classes b
      where a.classid(+) = b.classid;
STUDENTNO STUDENTNAM CLASSNAME
---------- ---------- ------------------------------
            1 aa          Ò»Äê¼¶Ò»°à
            2 bb          Ò»Äê¼¶¶þ°à
                           ......

Oracle & SUN£¬ÑϾþµÄÌôÕ½£¨Ò»£©

      ½ñÌì²Î¼ÓÁËOracle & SUNºÏ²¢ºóµÚÒ»´ÎÓëºÏ×÷»ï°é¼°¿Í»§µÄÍ¨Æø»á¡£Õû¸ö»áÒ鏸ÎҵĸоõÊÇ£ºOracleÐÛÐIJª²ª£¬SUNÒâÆø·ç·¢£¬¶øÎÒ×Ô¼º£¬ÐÄ»³ã·ã·¡£       OracleÓÐÁËSUN£¬ÄÇô´ÓÓ²¼þµ½Èí¼þOracleµÄ²úÆ·Ïß¾ÍÊ®·ÖÆë±¸ÁË¡£Oracle°ëÄêÇ°ÍÆ³ö11gR2 for linux£¬½Ó×Åfor solaris£¬¶øÖÁ½ñ¶¼Ã»ÓÐfor windows¡£ÕâÊÇ·ñÒâζ×Å£ºOracleÒÑÓÐ×ã¹»ÄÜÁ¦¶ÔÆäËûƽ̨˵²»¡£ÊÇ·ñÒâζ×Å£ºOracle½«½èÖúÆäÊý¾Ý¿âÊг¡µÄÁìÏȵØÎ»£¬È«ÃæÍƹãfor OracleµÄStorage¡¢Server¡¢OS¡¢Middleware¡¢APP¡£Èç¹ûÊÇ£¬ÄÇôOracle½«³ÉΪÊÂʵÉϵÄ¢¶ÏÕß¡£ÎÞÂÛSI¡¢Customer£¬¶¼½«Êܵ½¸ºÃæÓ°Ïì¡£       MySQLÔõô°ì£¿Èç¹ûOracle¼È²»¶ÔÆäÖ§³Ö¡¢Ò²²»¶ÔÆä·ÅÊÖ£¬ÉõÖÁͨ¹ý²ÏʳµÄÊÖ¶ÎÎüÊÕÆäÊг¡¡£ÄǺó¹û»áÔõÑù£¿¼Ó¾çOracle¶ÔÆóÒµ¼¶Êý¾Ý¿âÊг¡µÄ¢¶Ï£¿Õâ²¢·Ç½öÊÇÎҵı¯¹ÛÂÛµ÷£º½ñÌìÎÒÔڻ᳡ÉÏûÓÐÌýµ½ÈκιØÓÚMySQLδÀ´µÄ˵·¨£¬²¢ÇÒÏÖ³¡Ñ¯ÎÊOracle & SUNµÄ¸ß²ã¹ÙԱҲûÄܵõ½ÇåÎúµÄÏìÓ¦¡£Oracle¹ÙԱ˵²»·ÅÆú£¬Õâ²»ÊÇÎÒÃÇÏëÌýµ½µÄ£¬ÎÒÃÇÏ£ÍûOracleÄܶÔMySQL×ö³ö¹æ»®£¬·ñÔò¹í²ÅÏàÐÅËü»áÔ½À´Ô½ºÃ¡£       Ô­SUNµÄϵͳ×ܼàÔÚÑ ......

ÓÅ»¯select count(*) (תoracleÅàѵÀÏʦµÄÎÄÕÂ)


select count(*) from t1;
Õâ¾ä»°±È½Ï¼òµ¥£¬µ«ºÜÓÐÐþ»ú£¡¶ÔÕâ¾ä»°ÔËÐеÄÀí½â£¬·´Ó³ÁËÄã¶ÔÊý¾Ý¿âµÄÀí½âÉî¶È£¡
½¨Á¢ÊµÑéµÄ´ó±íËût1
SQL> conn scott/tiger
ÒÑÁ¬½Ó¡£
SQL> drop table t1 purge;
±íÒÑɾ³ý¡£
SQL> create table t1 as select * from emp where 0=9;
±íÒÑ´´½¨¡£
SQL> insert into t1 select * from emp;
ÒÑ´´½¨14ÐС£
SQL>  insert into t1 select * from t1;
ÒÑ´´½¨14ÐС£
SQL> /
ÒÑ´´½¨28ÐС£
SQL> /
ÒÑ´´½¨56ÐС£
SQL> /
ÒÑ´´½¨112ÐС£
SQL> /
ÒÑ´´½¨224ÐС£
SQL> /
ÒÑ´´½¨448ÐС£
SQL> /
ÒÑ´´½¨896ÐС£
SQL> /
ÒÑ´´½¨1792ÐС£
SQL> /
ÒÑ´´½¨3584ÐС£
SQL> /
ÒÑ´´½¨7168ÐС£
SQL> /
ÒÑ´´½¨14336ÐС£
SQL> /
ÒÑ´´½¨28672ÐС£
SQL> /
ÒÑ´´½¨57344ÐС£
SQL> commit;
Ìá½»Íê³É¡£
ÊÕ¼¯Í³¼ÆÐÅÏ¢
SQL> execute dbms_stats.gather_table_stats('SCOTT','T1');
PL/SQL ¹ý³ÌÒѳɹ¦Íê³É¡£
SQL> SET AUTOT TRACE EXP
SQL> SELECT COUNT(*) from T1;
Ö´Ðмƻ®
--------------------------------------------------       ......
×ܼǼÊý:40319; ×ÜÒ³Êý:6720; ÿҳ6 Ìõ; Ê×Ò³ ÉÏÒ»Ò³ [1549] [1550] [1551] [1552] 1553 [1554] [1555] [1556] [1557] [1558]  ÏÂÒ»Ò³ βҳ
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ