How To Stop A Running Datapump Job Started In Background [ID 958532.1]
Applies to:
Oracle Server - Enterprise Edition - Version: 10.1.0.2 and later [Release: 10.1 and later ]Information in this document applies to any platform.
Goal
The goal of this document is to demonstrate how a running Datapump job can be stopped.Suppose a session has started a Datapump export operation using the following UNIX command:
$ nohup expdp parfile=test.par &
The example in the document demonstrates how to stop this job from further processing. The same principles apply to jobs initiated using the DBMS_DATAPUMP API.
Solution
To stop the running job the name of the job must first be retrieved. This can be done using:connect / as sysdba
select owner, job_name from dba_datapump_jobs;
Once the job name is known, that particular job can be stopped by interactively attaching to that job using the ATTACH command line option of Datapump and then stop the job. The following example demonstrates this. The sample assumes that the owner of the job is SCOTT and the job name is TEST, so in this case EXPDP must connect to the SCOTT schema and attach to the TEST job:
$ expdp scott/tiger attach=test
Export: Release 11.2.0.1.0 - Production on Sat Oct 24 12:47:28 2009
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Job: TEST
Owner: TEST
Operation: EXPORT
Creator Privs: TRUE
GUID: 76AA1EE3F300E784E040B10A543B0825
Start Time: Saturday, 24 October, 2009 12:47:28
Mode: SCHEMA
Instance: ORA11GR2
Max Parallelism: 0
EXPORT Job Parameters:
Parameter Name Parameter Value:
CLIENT_COMMAND scott/******** parfile=test.par
State: DEFINING
Bytes Processed: 0
Job Error Count: 0
Dump File: /u02/app/oracle/admin/ORA11GR2/dpdump/test_23oct_rr.dmp
bytes written: 4,096
Export>
Once attached to the job interactively you can manipulate the job. In order to stop the job from running, the STOP_JOB command should be issued. When activated, the command asks for comfirmation. The answer "yes" should be provided to really stop the job:
Export> stop_job=immediate
Are you sure you wish to stop this job ([yes]/no): yes <<==
The DBA_DATAPUMP_JOBS view can be queried again to see that the job is not running anymore:
SQL> select job_name,state from dba_datapump_jobs;
JOB_NAME STATE
--------------------- -------------------------
TEST NOT RUNNING[@more@]
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/161195/viewspace-1057043/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- SharePoint 2013 workflows stop working (Failed on started.)AI
- Python程式碼解析: job = next(job for job in jobs if job.job_id == job_id)Python
- How to change the background color for PyCharmPyCharm
- Keep processes running in the background and even after SSH session disconnectsSession
- job任務均不執行,手工執行報job now running
- How To Turn SNMP On/Off ? [ID 472530.1]
- What is OPAQUE_TRANSFORM Hint and how to Control it [ID 780503.1]OpaqueORM
- How to Collect Diagnostics for Database Hanging Issues (Doc ID 452358.1)Database
- How to Increase CSS Misscount in single instance ASM installations [ID 729878.1]CSSASM
- 【CURSOR】How to Monitor and tune Open and Cached Cursors (Doc ID 1430255.1)
- How to redirect to a specific web page after sign out from Entra IDWeb
- How To Replicate Data from Oracle to Postgres Using GoldenGate (Doc ID 1544137.1OracleGo
- Datapump:EXCLUDE/INCLUDE
- 【ASK_ORACLE】刪除DBA_DATAPUMP_JOBS檢視中的異常資料泵JOB的方法Oracle
- rac中 crsctl start/stop crs and crsctl start/stop cluster 區別
- Get Started with EC2
- 1002 Running Median
- background-origin和background-clip區別
- 【Oracle】ORA-23421: job number XXXX is not a job in the job queueOracle
- datapump 匯出匯入ORA-07445
- ORACLE for aix 11.2.0.1 DATAPUMP expdp之BUG 9470768OracleAI
- CSS background 背景CSS
- CSS background背景CSS
- background屬性
- background 屬性
- 優雅地亂玩Redux: Getting StartedRedux
- buuctf-pwn-get_started_3dsctf_20163D
- How to ssh
- [20220128]Check the datapump file header information in Oracle.txtHeaderORMOracle
- 【log3】background
- 背景圖-background定位
- CSS background-positionCSS
- CSS background-sizeCSS
- CSS background-clipCSS
- CSS background-originCSS
- CSS:background-imageCSS
- Sqoop jobOOP
- pg_ctl stop 的三種模式模式
- 在 Android 上使用協程(二):Getting startedAndroid