How to Stop or Kill or Restart a impdp job?
Step 1) View the JOB_NAME using dba_datapump_jobs issue STOP_JOB=IMMEDIATE command :
SET lines 1000
COL owner_name FORMAT a10;
COL job_name FORMAT a20
COL state FORMAT a11
COL operation LIKE state
COL job_mode LIKE state
select * from dba_datapump_jobs;
OWNER_NAME JOB_NAME OPERATION JOB_MODE STATE
---------- -------------------- ----------- ----------- -----------
OPER SYS_IMPORT_SCHEMA_01 IMPORT SCHEMA EXECUTING
Step 2) Attach the JOB_NAME with impdp :
impdp userid=oper/oper attach=SYS_IMPORT_SCHEMA_01
Import: Release 11.2.0.3.0 - Production on Fri Mar 1 13:33:15 2012
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Automatic Storage Management, OLAP, Data Mining
and Real Application Testing options
Job: SYS_IMPORT_SCHEMA_01
Owner: OPER
Operation: IMPORT
Creator Privs: TRUE
GUID: D6E23617727E2DD8E04334A911ACB1BA
Start Time: Friday, 01 March, 2012 13:31:14
Mode: SCHEMA
Instance: HMWEXHST
Max Parallelism: 1
EXPORT Job Parameters:
CLIENT_COMMAND oper/*** directory=cis_dump_dir schemas=JAYDEEP dumpfile=JAYDEEP.dmp logfile=JAYDEEP.log
IMPORT Job Parameters:
Parameter Name Parameter Value:
CLIENT_COMMAND oper/********@JTEST directory=DP_TEMP_DIR schemas=JAYDEEP dumpfile=JAYDEEP.dmp logfile=JAYDEEP.log
State: EXECUTING
Bytes Processed: 0
Current Parallelism: 1
Job Error Count: 0
Dump File: /tempbkup/JAYDEEP/expdp/JAYDEEP.dmp
Worker 1 Status:
Process Name: DW00
State: EXECUTING
Object Schema: CIS_HISTORY_2010_3
Object Name: TICKETS_HIST
Object Type: SCHEMA_EXPORT/TABLE/TABLE_DATA
Completed Objects: 1
Completed Rows: 3,437,594
Completed Bytes: 40,101,139,632
Percent Done: 2
Worker Parallelism: 1
Import> STOP_JOB=IMMEDIATE
or
HELP
STATUS
CONTINUE_CLIENT
KILL_JOB
START_JOB
PARALLEL
STOP_JOB
Are you sure you wish to stop this job ([yes]/no): yes
How to monitor the progress of impdp jobs ?
select username,opname,target_desc,sofar,totalwork,message from V$SESSION_LONGOPS;
OPER SYS_IMPORT_SCHEMA_01 IMPORT 95641 95641 SYS_IMPORT_SCHEMA_01: IMPORT : 95641 out of 95641 MB done
Other useful command for interactive command for Data Pump:
HELP
STATUS : Check the status
CONTINUE_CLIENT : Resume the job
KILL_JOB : Detach all currently attached client sessions and terminate the current job
START_JOB : Restart a stopped job to which you are attached.
PARALLEL : Increase or decrease the number of active worker processes for the current job
STOP_JOB : Stop the current job.
Step 1) View the JOB_NAME using dba_datapump_jobs issue STOP_JOB=IMMEDIATE command :
SET lines 1000
COL owner_name FORMAT a10;
COL job_name FORMAT a20
COL state FORMAT a11
COL operation LIKE state
COL job_mode LIKE state
select * from dba_datapump_jobs;
OWNER_NAME JOB_NAME OPERATION JOB_MODE STATE
---------- -------------------- ----------- ----------- -----------
OPER SYS_IMPORT_SCHEMA_01 IMPORT SCHEMA EXECUTING
Step 2) Attach the JOB_NAME with impdp :
impdp userid=oper/oper attach=SYS_IMPORT_SCHEMA_01
Import: Release 11.2.0.3.0 - Production on Fri Mar 1 13:33:15 2012
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Automatic Storage Management, OLAP, Data Mining
and Real Application Testing options
Job: SYS_IMPORT_SCHEMA_01
Owner: OPER
Operation: IMPORT
Creator Privs: TRUE
GUID: D6E23617727E2DD8E04334A911ACB1BA
Start Time: Friday, 01 March, 2012 13:31:14
Mode: SCHEMA
Instance: HMWEXHST
Max Parallelism: 1
EXPORT Job Parameters:
CLIENT_COMMAND oper/*** directory=cis_dump_dir schemas=JAYDEEP dumpfile=JAYDEEP.dmp logfile=JAYDEEP.log
IMPORT Job Parameters:
Parameter Name Parameter Value:
CLIENT_COMMAND oper/********@JTEST directory=DP_TEMP_DIR schemas=JAYDEEP dumpfile=JAYDEEP.dmp logfile=JAYDEEP.log
State: EXECUTING
Bytes Processed: 0
Current Parallelism: 1
Job Error Count: 0
Dump File: /tempbkup/JAYDEEP/expdp/JAYDEEP.dmp
Worker 1 Status:
Process Name: DW00
State: EXECUTING
Object Schema: CIS_HISTORY_2010_3
Object Name: TICKETS_HIST
Object Type: SCHEMA_EXPORT/TABLE/TABLE_DATA
Completed Objects: 1
Completed Rows: 3,437,594
Completed Bytes: 40,101,139,632
Percent Done: 2
Worker Parallelism: 1
Import> STOP_JOB=IMMEDIATE
or
HELP
STATUS
CONTINUE_CLIENT
KILL_JOB
START_JOB
PARALLEL
STOP_JOB
Are you sure you wish to stop this job ([yes]/no): yes
How to monitor the progress of impdp jobs ?
select username,opname,target_desc,sofar,totalwork,message from V$SESSION_LONGOPS;
OPER SYS_IMPORT_SCHEMA_01 IMPORT 95641 95641 SYS_IMPORT_SCHEMA_01: IMPORT : 95641 out of 95641 MB done
Other useful command for interactive command for Data Pump:
HELP
STATUS : Check the status
CONTINUE_CLIENT : Resume the job
KILL_JOB : Detach all currently attached client sessions and terminate the current job
START_JOB : Restart a stopped job to which you are attached.
PARALLEL : Increase or decrease the number of active worker processes for the current job
STOP_JOB : Stop the current job.
No comments:
Post a Comment