Oracle DBMS_SCHEDULER 백업 설정 스크립트
1. create_program
BEGIN
-- Shell Script.
DBMS_SCHEDULER.create_program (
program_name => 'hotbackup_executable_prog',
program_type => 'EXECUTABLE',
program_action => '/backup/hotbackup/test.sql',
number_of_arguments => 0,
enabled => TRUE,
comments => 'Program to gather SCOTT''s statistics us a shell script.');
END;
/
2. create_schedule
BEGIN
DBMS_SCHEDULER.create_schedule (
schedule_name => 'test_min_schedule',
start_date => SYSTIMESTAMP,
repeat_interval => 'freq=MINUTELY; INTERVAL=30',
end_date => NULL,
comments => 'Repeats hourly, on the hour, for ever.');
END;
/
3. create_job
BEGIN
DBMS_SCHEDULER.create_job (
job_name => 'test_prog_sched_job_definition',
program_name => 'hotbackup_executable_prog',
schedule_name => 'test_min_schedule',
enabled => TRUE,
comments => 'Job defined by an existing program and schedule.');
END;
/
'1. IT Story > Scripts' 카테고리의 다른 글
Oracle 암/복호화 (DBMS_CRYPTO) 스크립트 (0) | 2019.02.22 |
---|---|
DB PROFILE/BASH_PROFILE 적용 스크립트 (0) | 2019.02.19 |
ORACLE SCN HELTH CHECK (0) | 2019.02.17 |
Mysql DB 기본 점검 스크립트 (0) | 2019.02.09 |
Oracle Hot Backup 스크립트 (0) | 2019.02.05 |
Oracle 테이블스페이스 용량확인 스크립트 (0) | 2019.02.04 |
Oracle 권한확인 스크립트 (0) | 2019.02.03 |
Oracle SEGMENT STAT 조회 스크립트 (0) | 2019.01.29 |