MERCADOS FINANCIEROS

miércoles, 6 de mayo de 2020

Monitorear Backups - Restore RMAN

col rj_sid head "SID" for 999999
col rj_serial head "Serial" for 999999
col rj_context head "Context" for 999999
col rj_sofar head "so far" for 99999999
col rj_totalwork head "Total" for 999999999
col rj_completed head "Completed" for 99.99
col rj_opname head "Operation" for a50
col rj_remain head "Remain" format a10

SELECT SID rj_sid,
  serial# rj_serial,
  CONTEXT rj_context,
  sofar rj_sofar,
  totalwork rj_totalwork,
  ROUND (sofar / totalwork * 100, 2) rj_completed,
  opname rj_opname,
  TO_CHAR(TRUNC(time_remaining            /60/60),'09')
  ||TO_CHAR(TRUNC(mod(time_remaining,3600)/60),'09')
  ||TO_CHAR(mod(mod(time_remaining,3600),60),'09') rj_remain
   FROM v$session_longops
  WHERE opname LIKE 'RMAN%'
AND totalwork != 0
AND sofar     <> totalwork
ORDER BY 1;


column event format a40
column username format a20
set linesize 200
set pagesize 20
SELECT inst_id, SID,EVENT, WAIT_TIME, SEQ#,STATE, seconds_in_wait, username, program FROM GV$SESSION
WHERE EVENT NOT IN ('VKRM Idle','lreg timer','heartbeat redo informer','AQPC idle','EMON slave idle wait','SQL*Net message from client', 'pmon timer','rdbms ipc message','virtual circuit next request','GCR sleep','JOX Jit Process Sleep',
'smon timer','slave wait','SQL*Net message to client','pipe get','gcs remote message','ges remote message','wakeup time manager','PX Deq: reap credit','PX Deq: Execute Reply','global cache cr request','jobq slave wait','ASM background timer','DIAG idle wait','class slave wait','jobq slave wait','PX Deq: Execution Msg','fbar timer','VKTM Logical Idle Wait','Space Manager: slave idle wait','PING','wait for unread message on broadcast channel','LNS ASYNC end of log',
'watchdog main loop','pman timer','gcs yield cpu','LGWR worker group idle','LGWR worker group idle','ASM cluster membership changes','Streams AQ: qmn slave idle wait','Data Guard: Gap Manager',
'Streams AQ: qmn coordinator idle wait','REPL Capture/Apply: RAC AQ qmn coordinator','watchdog main loop','OFS idle','watchdog main loop','SCM slave idle','Data Guard: Timer','Streams AQ: waiting for time management or cleanup tasks','watchdog main loop',
'pman timer','gcs yield cpu','ASM cluster membership changes','Data Guard: Timer','watchdog main loop','OFS idle','watchdog main loop','LGWR worker group idle','LGWR worker group idle','SCM slave idle','Data Guard: Gap Manager',
'REPL Capture/Apply: RAC AQ qmn coordinator','Streams AQ: waiting for time management or cleanup tasks','Streams AQ: qmn slave idle wait','Streams AQ: qmn coordinator idle wait','Data Guard: controlfile update','LNS ASYNC dest activation','parallel recovery slave next change','SQL*Net more data from client','MRP redo arrival','parallel recovery slave next change','parallel recovery slave next change','LMS CR slave timer','ASM IO for non-blocking poll','cell ram cache population');

No hay comentarios: