There are many Oracle backup methods. The following describes the oracle backup methods in windows. If you are interested in Oracle backup, take a look.
The oracle backup is named rman backup, so that you can perform full backup and Incremental backup. You can use the task plan to set backup policies. For example, you can perform level 0 backup every Monday, perform Level 1 backup from Tuesday to Sunday. Note that the archive log mode must be enabled when rman is used for backup.
1. Create a level 0 backup batch file backup_0.bat with the following content:
- set oracle_sid=oaserver
- rman target / msglog c:\logs\%date:~0,10%.log cmdfile=oaserver_backup_0.txt
Create the backup_0.txt file of the responsible oracle_region after 2XX, the content is as follows:
- run{
- allocate channel 'd1' type disk;
- allocate channel 'd2' type disk;
- allocate channel 'd3' type disk;
- allocate channel 'd4' type disk;
- backup incremental level 0 cumulative tag 'db0' format 'E:\oaserver\backup\db0%u_%s_%p' database;
- sql 'alter system archive log current';
- backup filesperset 4 archivelog all delete input;
- delete noprompt obsolete;
- release channel d1;
- release channel d2;
- release channel d3;
- release channel d4;
- }
- list backup;
- crosscheck backup;
- delete noprompt expired backup;
- delete noprompt obsolete;
- exit;
- EOF
- echo "-------------------------end------------------------------";date
3. Add a task scheduler. Use the task scheduler Wizard to set the time frequency for automatic task execution based on the Oracle backup policy, for example, every day. Execute backup_0.bat.
4. Create a batch file backup_1.bat for level 1 backup (Incremental Backup). The content is as follows:
- set oracle_sid=oaserver
- rman target / msglog c:\logs\%date:~0,10%.log cmdfile=oaserver_backup_1.txt
5. After creating the file backup_1.txt, the content is as follows:
- run{
- allocate channel 'd1' type disk;
- allocate channel 'd2' type disk;
- allocate channel 'd3' type disk;
- allocate channel 'd4' type disk;
- backup incremental level 1 cumulative tag 'db1' format 'E:\oaserver\backup\db1%u_%s_%p' database;
- sql 'alter system archive log current';
- backup filesperset 4 archivelog all delete input;
- delete noprompt obsolete;
- release channel d1;
- release channel d2;
- release channel d3;
- release channel d4;
- }
- list backup;
- crosscheck backup;
- delete noprompt expired backup;
- delete noprompt obsolete;
- exit;
- EOF
- echo "-------------------------end------------------------------";date
6. Add a task scheduler. Use the task scheduler Wizard to set the time frequency for automatic task execution based on the backup policy, for example, every day. Execute backup_1.bat.
Oracle control file recovery
Oracle single row date functions
Introduction to Oracle bitand () Functions
This section describes the types of oracle grouping functions.
Use of oracle Aggregate functions