jinfeng_wang

          G-G-S,D-D-U!

          BlogJava 首頁 新隨筆 聯系 聚合 管理
            400 Posts :: 0 Stories :: 296 Comments :: 0 Trackbacks
          session1  (sysdba)
              1) : alter session set timed_statistics=true;

              2 ) select * from v$session where v$session.USERNAME='SCOTT'; //find the trace session

              3)  exec dbms_system.set_sql_trace_in_session(25,6,true);  //open the sql_trace for the session

          session2  (scott)
              4) select * from t;

          session 1(sysbda)
              5) exec dbms_system.set_sql_trace_in_session(25,6,false); //close the sql_trace
             
              6) show parameter user_dump;  //get the trace file path

          session 3: OS,
              7)  cd /opt/oracle/diag/rdbms/orcl/orcl/trace
              8) ll -t  *.trc   //get the last trc file

              9) /opt/oracle/product/11.1.x/bin/tkprof /opt/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_7688.trc /opt/oracle/diag/rdbms/orcl/orcl/trace/
          orcl_ora_7688.trc.txt

             
             
          posted on 2009-10-25 14:29 jinfeng_wang 閱讀(903) 評論(0)  編輯  收藏 所屬分類: oracle
          主站蜘蛛池模板: 新营市| 蒙阴县| 三都| 酒泉市| 抚宁县| 松原市| 宣汉县| 新乡县| 延安市| 山阳县| 东莞市| 白河县| 老河口市| 雅江县| 郯城县| 房产| 临城县| 儋州市| 双鸭山市| 青海省| 佛山市| 焦作市| 贺兰县| 定襄县| 蓬安县| 阿克| 苏尼特左旗| 乐清市| 囊谦县| 浪卡子县| 满洲里市| 沅陵县| 稻城县| 柳江县| 吴江市| 和田县| 泸定县| 从江县| 南昌县| 祁东县| 汉川市|