we want to know what kind of transaction extract is working on database? which program it is calling ?
Step1:
-------
Find out the extract info and get XID using below command from ggsci
GGSCI> send extract extractname, showtrans duration 30 MIN
Sending SHOWTRANS request to EXTRACT ENTNEW ...
Oldest redo log file necessary to restart Extract is:
Redo Log Sequence Number 6, RBA 2239791
-----------------------------------------------------------
XID: 1.8.209025
Items: 0
Extract: ENTNEW
Redo Thread: 1
Start Time: 2015-26-22:00:10:06
SCN: 0.2239791 (2239791)
Redo Seq: 6
Redo RBA: 1470
Status: Running
Step2:
-------
using XID find out ADDR from the v$transaction on database
select ADDR from v$transaction where xidusn='XID';
STEP3:
--------
using ADDR find out the SID from database;
select sid,serial#,event,machine,sql_id,seconds_in_wait,prev_sql_id,module,program,action from v$session where taddr='ADDR';
STEP4:
---------
using SQL_ID from step 3 find out the sql which is taking longtime on gg env
select
hash_value, address,
executions,buffer_gets, disk_reads,
round(buffer_gets/decode(executions, 0, 1, executions), 1) avg_gets,
round(disk_reads/decode(executions, 0, 1, executions), 1) avg_disk,
last_load_time,
module,
sql_fulltext
from v$sqlarea
where sql_id='&sql_id';
From step4 we will SQL text and SQL_ID for long running transaction :)
depend on skip or wait for transaction to complete on database
GGSCI > send extract ENTNEW, skiptrans 1.8.209025
------Oracle in memory ---
------Nikhil Tatineni ---
Step1:
-------
Find out the extract info and get XID using below command from ggsci
GGSCI> send extract extractname, showtrans duration 30 MIN
Sending SHOWTRANS request to EXTRACT ENTNEW ...
Oldest redo log file necessary to restart Extract is:
Redo Log Sequence Number 6, RBA 2239791
-----------------------------------------------------------
XID: 1.8.209025
Items: 0
Extract: ENTNEW
Redo Thread: 1
Start Time: 2015-26-22:00:10:06
SCN: 0.2239791 (2239791)
Redo Seq: 6
Redo RBA: 1470
Status: Running
Step2:
-------
using XID find out ADDR from the v$transaction on database
select ADDR from v$transaction where xidusn='XID';
STEP3:
--------
using ADDR find out the SID from database;
select sid,serial#,event,machine,sql_id,seconds_in_wait,prev_sql_id,module,program,action from v$session where taddr='ADDR';
STEP4:
---------
using SQL_ID from step 3 find out the sql which is taking longtime on gg env
select
hash_value, address,
executions,buffer_gets, disk_reads,
round(buffer_gets/decode(executions, 0, 1, executions), 1) avg_gets,
round(disk_reads/decode(executions, 0, 1, executions), 1) avg_disk,
last_load_time,
module,
sql_fulltext
from v$sqlarea
where sql_id='&sql_id';
From step4 we will SQL text and SQL_ID for long running transaction :)
depend on skip or wait for transaction to complete on database
GGSCI > send extract ENTNEW, skiptrans 1.8.209025
------Oracle in memory ---
------Nikhil Tatineni ---