Take a look at the following slides from Yuri Velikanov, you will find in 10 advices for your rman backup scripts. The first one is about logs ...
But i am not going to use scheduler. Cause , I have to wait for some operation to be completed before i run the backup.
It has nothing to do with using a scheduler. It is basic *nix output redirection. Works from a command line as well.
Have you actually looked at the rman reference? See Contents
Look at the command line options. Look especially at the command line option "LOG".
Look at the directive 'SPOOL TO'
But also beware that if you use either option, the output will go ONLY to the log or redirected output file, and not back to the screen. See my recent thread on that subject, here: spooling rman interactive session
I found a very useful things to generate log for daily:
rman target / log=/home/oracle/test/rmanlog.`date '+%a'` << EOF;
It would give you date wise log. But How can i add date to this??? Any addition...to this???
Look up the other format options for the unix command 'date', in any unix/linux reference. Google is your friend, but only if you use it.
Hint: issue this command at your *nix os prompt:
Hi, for what its worth this is the script that i use that also emails me the details and also the amount of space in the FRA:
today="`date +%d%m%Y`" # month number, day of month, year
rman target / catalog rman/cat@TST1A log=$rlog<< EOF
DELETE NOPROMPT BACKUP;
allocate channel t1 type disk;
( database tag=tst1aFB );
delete noprompt archivelog until time 'SYSDATE-3';
release channel t1;
SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
sqlplus '/as sysdba' <<EOF
spool $rlog append
select * from V\$FLASH_RECOVERY_AREA_USAGE;
mailx -s "RMAN backup results" $Email1 <$rlog