Hi,
For just reference.
Control file backup
SQL>alter database backup controlfile to trace;
check $ORACLE_HOME/admin/<sid>/udump/<sid>_ora_xxxx.trc CREATE TEXT FILE.
SQL>alter database backup controlfile to 'c:\ctl.bak';
Above statement create binary control file.
or set
C:\> RMAN TARGET=SYS
PASSWORD: XXXXXXX
RMAN> configure controlfile autobackup on;
Whenever you take database backup above statement take CONTROL FILE and SPFILE backup automatically
Database files + archive log files
RUN
{
DELETE NOPROMPT OBSOLETE;
CROSSCHECK BACKUP;
CROSSCHECK ARCHIVELOG ALL;
DELETE NOPROMPT EXPIRED BACKUP;
DELETE NOPROMPT EXPIRED ARCHIVELOG ALL;
ALLOCATE CHANNEL C1 DEVICE TYPE DISK MAXPIECESIZE 100M;
ALLOCATE CHANNEL C2 DEVICE TYPE DISK MAXPIECESIZE 100M;
ALLOCATE CHANNEL C3 DEVICE TYPE DISK MAXPIECESIZE 100M;
BACKUP INCREMENTAL LEVEL 0 DATABASE TAG Weekly_Friday_0_Hotdb02_bkp;
SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
BACKUP DATABASE ARCHIVELOG ALL DELETE ALL INPUT TAG Weekly_Friday_0_Hotdb02_bkp;
BACKUP VALIDATE DATABASE;
BACKUP VALIDATE DATABASE ARCHIVELOG ALL;
}
Note: you have to also set RETENTION POLICY.
Above all just example and reference ...now you must visit below URL and read / understand then create you own script for RMAN backup.
http://download.oracle.com/docs/cd/B14117_01/server.101/b10734/toc.htm
Regards
Taj