-
Help: RMAN backup script
Hi guys, its me, the Oracle 8i guy again.
I put together the script below to do my database and archive log backups. However, I would like to backup my controlfile to a file and not to trace. Is there a way to do this within the script?
Thanks
ALLOCATE CHANNEL CH1 TYPE DISK;
ALLOCATE CHANNEL CH2 TYPE DISK;
ALLOCATE CHANNEL CH3 TYPE DISK;
BACKUP FORMAT ‘E:\ORACLE\ORADATA\ORABKP\%d_t%t_p%p’ (database);
SQL ‘ALTER SYSTEM ARCHIVELOG CURRENT’;
BACKUP (ARCHIVELOG ALL DELETE INPUT);
SQL ‘ALTER DATABASE BACKUP CONTROLFILE TO TRACE’;
RESYNC CATALOG;
}
-
SQL ‘ALTER DATABASE BACKUP CONTROLFILE TO 'C:\oracle\control_bck.ctl';
anandkl
-
Thants the same thing that I thought, but I got the error below...
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01005: syntax error: found "identifier": expecting one of: ";"
RMAN-01008: the bad identifier was: D
RMAN-01007: at line 8 column 44 file: standard input
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01006: error signalled during parse
RMAN-02001: unrecognized punctuation symbol ":"
-
Just curious, why would you want an additional copy of the controlfile?
Jeff Hunter
-
Originally posted by marist89
Just curious, why would you want an additional copy of the controlfile?
Well I just want to ensure that I am doing everything to protect my system/data in the event of some sort of failure. And I want to omit the copy to the trace file.
-
Hi,
You need to use double quotes
sql "alter database backup controlfile to ''C:\oracle\control_bck.ctl''";
regards
anandkl
anandkl
-
Thanks,
Can someone tell me how do I schedule a stored rman script to automatically run?
-
Originally posted by razorren
Thanks,
Can someone tell me how do I schedule a stored rman script to automatically run?
Use any scheduling utility - cron, at, OEM etc..
-
What operating system do you have and when do you want to run them?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|