Hi,
Before scheduling RMAN jobs through dbms_scheduler, I tried to run an expdp job through dbms_scheduler.
My Test_expdp.bat file is as below:
- Code: Select all
set ORACLE_SID=TESTS
set ORACLE_HOME=E:\Oracle\product\11.2.0\dbhome
expdp system/**** DUMPFILE=expdp_test_"%date:~7,2%%date:~4,2%%date:~10,4%".dmp LOGFILE=expdp_test_"%date:~7,2%%date:~4,2%%date:~10,4%".log Schemas=TEST1 JOB_NAME=expdp_test
--------------------------------------------------------------------------------------------------------------
And I am creating job as below:
- Code: Select all
begin
DBMS_SCHEDULER.create_job (
job_name => 'test_expdp',
job_type => 'EXECUTABLE',
job_action => 'c:\windows\system32\cmd.exe /c C:/Users/Mark/Desktop/Mark/Test_expdp.bat',
start_date => to_date('10/26/2012 14:52:00','mm/dd/yyyy hh24:mi:ss'),
repeat_interval => 'FREQ=DAILY;BYHOUR=14;BYMINUTE=52;BYSECOND=00',
enabled => TRUE);
end;
/
But this never runs or gives errors like below:
ORA-27301: OS failure message: The pipe has been ended.
ORA-27302: failure occurred at: sjsec 9
ORA-27303: additional information: The pipe has been ended.
FAILED 1
ORA-27369: job of type EXECUTABLE failed with exit code: Incorrect function.
STANDARD_ERROR="'expdp' is not recognized as an internal or external command,
operable program or batch file."
Please suggest.