Sql trace file

hi,
when i am analyzing sql trace file it is showing like 1 sql statement in sql trace file, 1 user sql statements are traced
enabling sql_trace=true as a sys user only.
is there any problem it is not gathering all the users sql statements.

user8647245 wrote:
yes, your right,
Sort options: default
1 session in tracefile.
1 user sql statements in trace file
0 internal sql statements in trace file
1 sql statements in trace file
like this.
user1 and scott users are connected to database.SQL session can be traced at a time for only one user i.e. one session. It you enable sql trace, During this time if you run any SQL or programs, It will gather all trace of your queries.
Your output depends on Your input i.e. which transactions/queries you have executed.
For ex:
execute dbms_system.set_sql_trace_in_session(<sid>, <serial>, true);

Similar Messages

  • Create sql trace files on client machine

    Hi
    oracle creates sql trace files on server side, what are possible and best ways of sharing those files with end users? is it possible to create them on client side instead?

    Dbb wrote:
    Hi
    Hi
    oracle creates sql trace files on server side,
    Yes
    what are possible and best ways of sharing those files with end users?
    Using shared directory. Use the parameters dump to point to it
    is it possible to create them on client side instead?
    No
    . :-) any help with my english is wellcome :-) .does this mean sharing user_dump destination at linux level and then mounting it from client machines ( win xp )?is there any doc on this?

  • Unable to generate SQL trace file on a 10.2.0.1.0 database

    Hello,
    I am unable to generate SQL trace files on a 10.2.0.1.0 database (OS is Win2003 server 64 bits).
    First I tried the way I used to do it on older databases (8i and 9i) :
    execute dbms_system.set_sql_trace_in_session(sid, serial#, true);
    I got no error, but no file was created in the user dump dest directory.
    Then I've been searching and I've tried other things :
    - I changed the user_dump_dest parameter
    - I changed the tracefiles_public parameter value to "true", by modifying the init.ora file
    - I tried another package :
    exec dbms_monitor.session_trace_enable(139)
    Nothing worked, I can't create any trace file...
    Does anyone have an idea about this issue ?
    thank you for you help !
    Antoine

    Hello,
    thank you all for replying.
    I have 2 instances on this machine, and I've just realized that with the other one I have no problem to generate sql trace files as usual.
    But why the hell is it impossible on the first instance ? What difference between the 2 instances can explain this ?
    This is pretty weird...
    Otherwise I am experiencing serious performance problems on the instance where I can't creat trace files, there must be something wrong with it, but I can't figure it out
    regards,
    Antoine

  • Explain plan not displayed in sql trace file

    Hello,
    I don't understand why in sql trace file, after tkprof transformation, for several queries the explain plan is displayed and for several queries, no explain plan is displayed.
    How can I have the explain plan for all queries?
    Thanks for your help.

    Was this a trace started on an already running task? Was the trace stopped before the task completed? Did the trace file reach its set size limit before the task compled?
    In all three cases above you would have cursors that were not closed and stats information not written to the trace file resulting in incomplete data for some SQL.
    HTH -- Mark D Powell --

  • How to SQL trace File in udump Folder

    Hi,
    I kept the Sql Trace for one database. Now i am getting the bulk of files in udump folder. I tryed the command
    ALTER SESSION SET SQL_TRACE=FALSE
    to stop the trace, but it is not stoping.
    Now my problem is how to stop this file load in to that folder.
    Thank u,

    hi,
    Thank u alok, Thank u very much. its working fine.
    U told first that it is my mistake of enabling in database level. What are the real commands to start the trace and stop the trace by that session. What the Oracle Books says is this commands i followed ( Book name --- ORACLE HIGH PERFORMANCE TUNING FOR 9i AND 10g BY GAVIN POWELL ) Page -- 339
    ALTER SESSION SET TIMED_STATISTICS = TRUE;
    ALTER SESSION SET TIMED_OS_STATISTICS = 5;
    ALTER SESSION SET MAX_DUMP_FILE_SIZE=1M;
    ALTER SESSION SET SQL_TRACE = TRUE;
    ALTER SESSION SET STATISTICS = ALL;
    This command i followed. This is for session only, then why this is happened in database level.
    Can u provide me the commands for start and stop the SQL TRACE.
    Thank u for ur reply.

  • Unable to generate SQL trace file in shared mode ??

    Hello,
    I have a 10.2.0.1.0 database on Win2003 server 64 bits, with several instances.
    On instances in dedicated mode, I can create trace files by using dbms_system.set_sql_trace_in_session, but on instances in shared mode nothing happens : no file is created in the udump directory.
    This doesn't make any sense to me o_O
    The shared parameters are the following :
    dispatchers=(protocol=TCP)
    shared_servers=1
    I've checked all the necessary parameters to create a trace file (user_dump_dest, timed_statistics, max_dump_file_size...) and everything is fine.
    I really don't understand why I can't create trace files when the instance is in shared mdoe...
    Can anyone help about this weird issue ?
    thank you !
    regards,
    Antoine

    Remember also that in Shared Server mode the trace information is not written to a single file but is written to the Shared Server trace file. Before Oracle 10g there was no way to pull all the trace information for a single user session together out of the trace files. There is a tool for doing so with 10g.
    HTH -- Mark D Powell --

  • Record type variables in the SQL database trace file

    Hi,
    I turned on the trace with binds and waits in a ebusiness form and captured the database SQL trace file. It lists the values for the generic datatypes for the call, but does not list the values of record type variables. Is there a way to identify the values of record type variables? The below section lists the procedure call and the values passed. Thanks in advance.
    RPC CALL:PROCEDURE APPS.HZ_PARTY_SEARCH.FIND_PARTY_DETAILS(P_INIT_MSG_LIST IN VARCHAR2, P_RULE_ID IN NUMBER, P_PARTY_SEARCH_REC IN PARTY_SEARCH_REC_TYPE, P_PARTY_SITE_LIST IN PARTY_SITE_LIST, P_CONTACT_LIST IN CONTACT_LIST, P_CONTACT_POINT_LIST IN CONTACT_POINT_LIST
    , P_RESTRICT_SQL IN VARCHAR2, P_MATCH_TYPE IN VARCHAR2, P_SEARCH_MERGED IN VARCHAR2, X_SEARCH_CTX_ID OUT NUMBER, X_NUM_MATCHES OUT NUMBER, X_RETURN_STATUS OUT VARCHAR2, X_MSG_COUNT OUT NUMBER, X_MSG_DATA OUT VARCHAR2);
    RPC BINDS:
    bind 0: dty=1 bfp=2ae5927c13c8 flg=08 avl=01 mxl=01 val="T"
    bind 1: dty=6 bfp=2ae5927c13f0 flg=00 avl=02 mxl=22 val=8
    bind 2: dty=118 bfp=2ae593432e48 flg=00 avl=00 mxl=00 val=00
    bind 3: dty=251 bfp=2ae5929ac0b8 flg=00 avl=1944 mxl=00 val=00
    bind 4: dty=251 bfp=2ae592d85548 flg=00 avl=5336 mxl=00 val=00
    bind 5: dty=251 bfp=2ae592d84d58 flg=00 avl=4984 mxl=00 val=00
    bind 6: dty=1 bfp=2ae5927c1550 flg=08 avl=125 mxl=2000 val="exists (select 'x' from hz_parties where party_id =stage.party_id and party_type = 'ORGANIZATION') and party_id <>1002277174"
    bind 7: dty=1 bfp=2ae5927c1d50 flg=0a avl=00 mxl=00 val=""
    bind 8: dty=1 bfp=2ae5927c1d80 flg=08 avl=01 mxl=01 val="I"
    bind 9: dty=6 bfp=2ae5927c1da8 flg=02 avl=00 mxl=22 val=00
    bind 10: dty=6 bfp=2ae5927c1de0 flg=02 avl=00 mxl=22 val=00
    bind 11: dty=1 bfp=2ae5927c1e28 flg=0a avl=00 mxl=01 val=""
    bind 12: dty=6 bfp=2ae5927c1e50 flg=02 avl=00 mxl=22 val=00
    bind 13: dty=1 bfp=2ae5927c1e98 flg=0a avl=00 mxl=2000 val=""

    Hello,
    From the sounds of it, when you are adding a child the application is not maintaining the Company's reference to it. For instance, in a 1:M and M:1 relationship, the application seems to be setting only the M:1 part (child to parent) which will cause the database to be updated, but both sides need to be set to keep the cache in synch with the database.
    Setting the cache type to be none is not a good idea - it prevents any caching, which will hurt performance and object identity. What instead is recommended is disabling the shared cache using the
    toplink.cache.shared.<ENTITY>=false property. This still might not help though if the Company's reference to the child hasn't been set as mentioned above if you are reading Company from the same context you are adding the child.
    The Cache is described for TopLink Essentials in the blog at:
    http://weblogs.java.net/blog/guruwons/archive/2006/09/understanding_t.html
    Best Regards,
    Chris

  • Sql statement appear twice in trace file

    Hi all,
    Just a little confused on why my sql statement appear twice in the sql trace file.
    the following is the sequence of steps to reproduce this.
    1. Enable sql trace in another session, say session B
    exec dbms_monitor.session_trace_enable(38,13330,TRUE,TRUE);2. Execute the following sql in session B
    select * from hosts where hostname = 'host19'3. Disable sql trace
    exec dbms_monitor.session_trace_disable(38,13330);I used TKPROF to parse the trace file
    tkprof DEV_ora_20621.trc DEV_ora_20621.out sys=noThe output is
    SQL ID: bcpw6ttb0xbqs
    Plan Hash: 0
    select *
    from
      hosts where hostname = 'host19'
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          5          0           0
    Execute      0      0.00       0.00          0          0          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        1      0.00       0.00          0          5          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 88
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       1        0.00          0.00
      SQL*Net message from client                     1        0.00          0.00
    SQL ID: bcpw6ttb0xbqs
    Plan Hash: 3617124623
    select *
    from
      hosts where hostname = 'host19'
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          0          0           0
    Fetch        1      0.00       0.00          0          3          0           1
    total        3      0.00       0.00          0          3          0           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 88
    Rows     Row Source Operation
          1  TABLE ACCESS BY INDEX ROWID HOSTS (cr=3 pr=0 pw=0 time=0 us cost=2 size=135 card=1)
          1   INDEX RANGE SCAN IDX_HOST01 (cr=2 pr=0 pw=0 time=0 us cost=1 size=0 card=1)(object id 78193)Why the sql is showing twice?
    I think the correct one would be the second since it's reporting the fetching of 1 row.
    Does anyone understand this?
    Cheers,
    -Joel
    Edited by: user12057365 on Jul 21, 2010 1:59 AM

    Could not reproduce this in my 10.2.0.4.0 environment. Whats your Oracle version?

  • Extract SQL history from 10046 trace files

    Hi all,
    I need to extract the complete sql history from sql trace files to "debug" a client application.
    I know I can read the raw trc file and rebuild the sql history looking for the PARSING / EXEC / FETCH entries.
    However, this is a very long and boring manual task: do you know if there is some free tool to automate this task?
    thanks
    Andrea

    user585511 wrote:
    I agree that the 10046 trace captures everything. If I do read the raw trc file I see the DML. The problem is that tkprof's record does not record the DML (maybe it thinks that some DML is recursive sql and it gets misleaded... I am not sure) so I am looking for an alternate tool to process 10046 trace files
    Regards
    AndreaReally?
    Generate a trace of some dml:
    oracle:orcl$
    oracle:orcl$ sqlplus /nolog
    SQL*Plus: Release 11.2.0.1.0 Production on Thu May 16 08:28:55 2013
    Copyright (c) 1982, 2009, Oracle.  All rights reserved.
    SQL> conn snuffy/snuffy
    Connected.
    SQL> alter session set tracefile_identifier = "snuffy_session";
    Session altered.
    SQL> alter session set events '10046 trace name context forever, level 12';
    Session altered.
    SQL> insert into mytest values (sysdate);
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> ALTER SESSION SET EVENTS '10046 trace name context off';
    Session altered.
    SQL> exitrun tkprof on the trace
    oracle:orcl$ ls -l $ORACLE_BASE/diag/rdbms/$ORACLE_SID/$ORACLE_SID/trace/*snuffy
    *.trc
    -rw-r----- 1 oracle asmadmin 3038 May 16 08:29 /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_4086_snuffy_session.trc
    oracle:orcl$ tkprof /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_4086_snu
    ffy_session.trc snuffy.rpt waits=YES sys=NO explain=system/halftrack
    TKPROF: Release 11.2.0.1.0 - Development on Thu May 16 08:31:32 2013
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.Look at the report:
    oracle:orcl$ cat snuffy.rpt
    TKPROF: Release 11.2.0.1.0 - Development on Thu May 16 08:31:32 2013
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    Trace file: /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_4086_snuffy_session.trc
    Sort options: default
    count    = number of times OCI procedure was executed
    cpu      = cpu time in seconds executing
    elapsed  = elapsed time in seconds executing
    disk     = number of physical reads of buffers from disk
    query    = number of buffers gotten for consistent read
    current  = number of buffers gotten in current mode (usually for update)
    rows     = number of rows processed by the fetch or execute call
    SQL ID: 938dgt554gu98
    Plan Hash: 0
    insert into mytest           <<<<<<<<<<<<<<<< oh my!  Here is the insert statement
    values
    (sysdate)
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          1          5           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          1          5           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 86  (SNUFFY)
    Rows     Row Source Operation
          0  LOAD TABLE CONVENTIONAL  (cr=1 pr=0 pw=0 time=0 us)
    error during execute of EXPLAIN PLAN statement
    ORA-00942: table or view does not exist
    parse error offset: 83
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       1        0.00          0.00
      SQL*Net message from client                     1        3.35          3.35
    SQL ID: 23wm3kz7rps5y
    Plan Hash: 0
    commit
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          0          1           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          0          1           0
    Misses in library cache during parse: 0
    Parsing user id: 86  (SNUFFY)
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       2        0.00          0.00
      SQL*Net message from client                     2        4.72          8.50
      log file sync                                   1        0.00          0.00
    SQL ID: 0kjg1c2g4gdcr
    Plan Hash: 0
    ALTER SESSION SET EVENTS '10046 trace name context off'
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          0          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          0          0           0
    Misses in library cache during parse: 0
    Parsing user id: 86  (SNUFFY)
    OVERALL TOTALS FOR ALL NON-RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        3      0.00       0.00          0          0          0           0
    Execute      3      0.00       0.00          0          1          6           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        6      0.00       0.00          0          1          6           1
    Misses in library cache during parse: 0
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       3        0.00          0.00
      SQL*Net message from client                     3        4.72         11.86
      log file sync                                   1        0.00          0.00
    OVERALL TOTALS FOR ALL RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        0      0.00       0.00          0          0          0           0
    Execute      0      0.00       0.00          0          0          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        0      0.00       0.00          0          0          0           0
    Misses in library cache during parse: 0
        3  user  SQL statements in session.
        0  internal SQL statements in session.
        3  SQL statements in session.
        0  statements EXPLAINed in this session.
    Trace file: /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_4086_snuffy_session.trc
    Trace file compatibility: 11.1.0.7
    Sort options: default
           1  session in tracefile.
           3  user  SQL statements in trace file.
           0  internal SQL statements in trace file.
           3  SQL statements in trace file.
           3  unique SQL statements in trace file.
          58  lines in trace file.
           8  elapsed seconds in trace file.
    oracle:orcl$

  • How to Generate Trace Files in SQL*Plus

    Hi Friends ,
    How to Generate Trace Files in SQL*Plus ?
    i have no idea
    thanks
    raj

    What trace files would you like to generate?
    Are we talking SQL trace files?
    ALTER SESSION SET sql_trace = TRUE;This will be generated in the user_dump_dest on the server.
    show parameter dump

  • Do you know Timmings for trace files generated?

    Hi,
    I have done some sql traceing using DBMS_MONITOR package.
    We can also enable SQL traceing using DBMS_SESSION.
    I want to generate sql trace file for "particuler part of application".
    When i did that i got some sql trace files,, now that "particuler part of application" was over application was idle..
    but as time goes these files are still populating in size means they are still sql traceing going on...
    My question is when and how trace files are generated?
    Do you have idea???
    Thanks and Regards,
    Rushang Kansara
    Message was edited by:
    Rush

    also what content of my sql trace file should i
    consider for exacly tracing that "particuler part of
    application".
    Rushang
    Parse Count To Execute Ratio
    Take the numbers of parse count and divide it by numbers of time execute count if it is 1 then it means you are parsing the same statment everytime,If this ratio is 1 then it will latch the shared SQL area which will degrade the overall performance.Like if you execute a query which is using bind variable and this query is at yours front end level trigger (Forms) POST_QUERY then it will show you (parse count=execute count) which shows you are parsing for every triggering event which is bad ,for that you should put this seqeuel within PL/SQL procedure which cache the cursor and will turn in (parse count<Execute Count).
    Large Diffrence Between Elasped Time And CPU Time
    If this diffrence (Elapsed time[b]-CPU time)>1 then it means you are spending yours time in for waiting resources this waiting resources will in turn wait events e.g some one updated the row and dont realease by COMMIT or ROLBACK and the same span of time you want to update then you will see a lock in tkprof result in wait event section.If you read the data from hard disk (as first time you issue it reads from HD and then put into buffer cache during this reading a latch is grabed and will not let you read this data until you perform the alls read from HD to buffer cache this will also show you in wait events which is cache buffers chain
    Fetch Calls
    If yours Fetch calls=Rows then it means you are not using Bulk fetch and yours this code will take a lot of roundtrips which will in turn jam the network.
    Disk Count
    If every time yours disk count=current + query mode then you are reading alls block from disk alls the time ,usually oracle read once from disk and put it into SGA and should be found in SGA second time.
    And there is many more...depend on yors environemnt setup but above are common.
    As you said its reproducing the tkprof again and again ,make sure you terminate the session or you explicitly turn off the tracer by
    ALTER SESSION SET SQL_TRACE=FALSE Khurram

  • OCCI/ODBC application sql trace failure...

    Hi,
    I was doing the sql*net trace for an OCCI/ODBC Application writen in c++. I have an InstantClient on my PC. I was trying to access the Oracle through my C++ program to
    compare the performance of OCCI and ODBC.
    I was using the Oracle 10g(ver10.2.0.1.0 ), Oracle instant cilent(win32-10.2.0.3-20061115), and VS 8.0.
    TNSNAMES.ora:
    ORCL =  
      (DESCRIPTION =
      (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = host_name)(PORT = 1521))
      (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = ORCL)
    (SID = ORCL)
    LISTENER.ORA:(It was created by net manager.)
    SID_LIST_LISTENER =
      (SID_LIST =
      (SID_DESC =
      (GLOBAL_DBNAME = ORCL)
      (ORACLE_HOME = F:\oracle\product\10.1.0\Db_3)
      (SID_NAME = ORCL)
    LISTENER =
      (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = HOST_NAME)(PORT = 1521))
    The sqlnet.ora file was writen to trace the client sql. Fortunately, my C++ program can access the oracle and get my result back successfully. In the same time, the trace files
    can be created, but when using the tkprof tool to explain it, it comes to the file with useless information.
    One of the *.trc file explaind by tkprof tool:
    Sort options: default
    count = number of times OCI procedure was executed
    cpu = cpu time in seconds executing
    elapsed = elapsed time in seconds executing
    disk = number of physical reads of buffers from disk
    query = number of buffers gotten for consistent read
    current = number of buffers gotten in current mode (usually for update)
    rows = number of rows processed by the fetch or execute call
    Trace file: ora21763.trc
    Trace file compatibility: 8.00.04
    Sort options: default
    1 session in tracefile.
    0 user SQL statements in trace file.
    0 internal SQL statements in trace file.
    0 SQL statements in trace file.
    0 unique SQL statements in trace file.
    327 lines in trace file.
    Finally, I got TNS-12518 TNS-12564 error. I tried to add DIRECT_HANDOFF_TTC_LISTENER=OFF, but it didnt work. I traced the listener, the error occured in the listener.trc "
    ntt2err: soc 464 error " and " nsbequeath: error reading REDIR/NSE msg".
    I just cann't get the right trace file and cann't sovle the two errors(TNS-12518 TNS-12564). Can somebody give me some advices, please.

    Hi,
    The TKPROF facility accepts as input an SQL trace file generated when SQL Trace has been turned on for the system or a session, not a SQL*NET trace file. A SQL*Net trace file is a dump of raw data packets and communications at the SQL*NET layer. If you want to get performance statistics from SQL beign executed by your application, then you need to turn on SQL Trace not SQL*MET tracing.
    To enable SQL trace at the system level, you need to execute:
    alter system set SQL_TRACE=TRUE
    The NS-12518 TNS-12564 normally means you are running into some sort of resource deletion issue. This can be caused by various things. Make sure you are properly cleaning up and closing sessions in your application.
    Are you performing some sort of stress test or have you just written a Multi-threaded test harness that executes different types of SQL with OCCI/ODBC?
    HTH
    J.B.

  • SQL Trace for schema level

    Hi
    Database 10.1.0.4
    Sql trace file which I have used but didn't get the trace file. I have tried to get per session Id but not able to get the trace file, when ever user logged into application, virtually 6 user get lgged in and you never know about user. So I have desided to capture for schema
    I have used this for tracing
    SQL> ALTER SESSION SET sql_trace=TRUE;
    SQL> ALTER SESSION SET sql_trace=FALSE;
    Or
    SQL> EXEC DBMS_SESSION.set_sql_trace(sql_trace => TRUE);
    SQL> EXEC DBMS_SESSION.set_sql_trace(sql_trace => FALSE);
    or
    SQL> EXEC DBMS_SYSTEM.set_sql_trace_in_session(sid=>123, serial#=>1234, sql_trace=>TRUE);
    SQL> EXEC DBMS_SYSTEM.set_sql_trace_in_session(sid=>123, serial#=>1234, sql_trace=>FALSE);
    I want to get trace file for schema, can anyone suggest how do I get trace file at schema level.
    Thanks for help

    Hi,
    Using instance-level tracing by setting the init.ora/spfile... parameter SQL_TRACE=TRUE, all processes against the instance will create their own trace files. This particular method of tracing should be used with care since it creates a great deal of overhead against the system. In addition, the default value for this parameter is FALSE.
    Cheers
    Legatti

  • Max wait from a trace file...what does it mean

    Hi,
    following is a part of an extended sql trace file :
    Elapsed times include waiting on following events:
    Event waited on Times Max. Wait Total Waited
    ---------------------------------------- Waited ---------- ------------
    library cache lock 5 0.00 0.00
    row cache lock 7 0.00 0.00
    library cache pin 3 0.00 0.00
    rdbms ipc reply 2 0.00 0.00
    SQL*Net message to client 8185 0.00 0.01
    SQLNet message from client 8185 1671.98 1688.26*
    here what does the column max.wait mean? this is a trace file when a proc was run remotely to a database - it has lots of dbms_output statements, it creates an output file (on the remote pc from which it runs) the proc calls several sql scrips, does lot of query and dml
    Now when teh same script is run locally from the server those sql net waits are not there. and the interesting fact is: when run locally it takes 4 mins
    and remotely it takes 1 hour. How can we interpret this? and what does teh max wait indiccate?
    thanks,

    Can you explain more on this? the same proc when run locally does not have this wait and when run from remote ip it has this wait - so does that mean that this is due to network issue?
    should we for example - remove the dbms_output statements from this and try ? what should we do to be able to run the script from remote ip and run it in 6-7 minutes- when the scritp is run locally from the from server it takes 4 minutes and from a remote ip it takes one hour. the script also has a spool statement as it has to log its output. Is it that spoling that may be causing this?
    Thanks again,
    Edited by: orausern on Jan 18, 2010 7:09 AM

  • TRACE FILE의 PERMISSION 조정하는 방법

    제품 : ORACLE SERVER
    작성날짜 : 1998-04-28
    제목
    ====
    oracle trace file 을 dba group 에 속하지 않는 user 들에게
    permission 을 허용하는 방법
    문제
    ====
    Oracle 의 모든 trace file 은 owner 가 oracle user, group 이
    dba 이고 640 permission 을 갖습니다.
    예를 들면, -rw-r----- oracle dba
    따라서, UNIX 에서는 $ORACLE_HOME/log 나 initSID.ora, configSID.ora 에
    지정된 directory 에 생성되는 모든 trace file 은 위의 permission 을
    갖기 때문에 dba group 에 속하지 않은 사용자들은 trace file 을
    access 할 수 없도록 되어 있습니다.
    해결
    ====
    tracefiles_public =true 라는 parameter 를 initSID.ora 에
    추가후 db restartup 하고, 일반 사용자들의 umask 를 000 으로
    setting 하시면 됩니다.
    1. cd $ORACLE_HOME/dbs
    2. UNIX,VMS 의 init<sid>.ora 에 다음을 추가하십시오.
    tracefiles_public=true
    3. save init<sid>.ora
    4. restartup database
    위 작업은 oracle trace file 이 trace 를 생성하는 사용자의 umask 에
    의해 trace file 의 permission 이 결정하도록 합니다.
    일반 사용자 가 OS prompt 상태에서
    $umask 000
    으로 한 다음 sql trace file 등을 생성하는 작업을 했을 때, 화일의
    permission 이 다음과 같이 생깁니다.
    -rw-rw-r-- 1 oracle dba 2945 Apr 16 10:11 ora_28494.trc
    즉, trace file 의 owner와 group 은 여전히 oracle, dba 이기 때문에, umask의
    세번째 field 가 0 이어야 dba group 이 아닌 일반 사용자 들이
    trace file 을 읽을 수 있습니다.
    참고
    ====
    재 기동 작업시에 다음 에러가 발생한다면, 위 파라미터의 spelling 등을 다시
    확인하십시오.
    ora-1078
    01078, 00000, "failure in processing system parameters"
    // *Cause:  Failure during processing of init.ora parameters during
    // system startup.
    // *Action:  Further diagnostic information should be in the errorstack. 
    lcc-122
    122, 0, "unrecognized keyword [%.*s]"
    // *Cause: You have misspelled the parameter name
    // *Action: Spell the parameter name correctly                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

Maybe you are looking for

  • Extract data from Query to a Flat File - scheduling in the background

    Hi All, We need to extract data from a query to a flat file periodically, but each time 10 separate executions based on 10 profit centers, to get the separate files. So, we have PC1, PC2, ... PC10 Profit centeres. We have Query1, with profit center v

  • How to rename with inverse rating in the filename?

    This is a question about sorting and renaming. I have a bunch of sports images in Lightroom that are all tagged with an appropriate rating or 1-5 stars.  Because they are sports images, some are sequences of images taken at 8fps. I want the images to

  • AirPort Express connected to an iPod Hi-Fi; iTunes can't find the speaker.

    Hi, I've been trying to get my Hi-Fi to show up in iTunes via an AirPort Express connected to a MBP without much success.. First I had some trouble connecting the Express to my exisisting wireless network (Wireless-N ADSL2+ Gateway WAG300N), but once

  • Point to Anchor in another tab?

    I can create a link with Point-to-File from the Properties panel, pointing to a local file in the Files list or pointing to an anchor in the current page. But I can't find a way to point to a named anchor in another page (already open in another edit

  • I Can't update to the 30.2012.07-1

    I got a prompt to update my N9 to version  30.2012.07-1 In the first step it downloads some files. After this finished fine it propted to "continue" with the installation. The installation screen remains at "Updating 0%" for several minutes and then