Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: RMAN backup of archived logs
I do it. create a variable and backup and delete based on how full my
archivelog mount point is..
IE. from 'sysdate -2' <== delete logs older than 2 days
Under rough situations when the mount point is getting full... I more agressively try to remove more logs.
'sysdate -.5' <== delete arc logs older than 12 hours .. 'sysdate - .01' <=== delete arc logs older than 14+ minutes
you will get an error 20242 when logs to be backed up/deleted dont exist in the time frame you are requesting...
you simply have to code this error as a not fatal error... Your job actually did not fail...it just notified you it had no arc logs to work with.
I keep 2 days of logs on disk but under heavy arc production you have to backup them up or GZIP them to ensure your mount point does not fill up.
Cheers,
brian
-----Original Message-----
Sent: Friday, May 02, 2003 5:17 PM
To: Multiple recipients of list ORACLE-L
On page 224 of Mr. Freeman's RMAN book there's an example
backup archivelog all delete input until time 'sysdate - 2';
That command produces a syntax error message in RMAN for Oracle 9.2.0.1.
I find that changing the command to
backup archivelog all until time 'sysdate - 2' delete input;
works successfully.
What I'd like to do now is, in one command, backup all archived logs and delete only those older than a specified time?
Failing that, I've tried
backup archivelog all until time 'sysdate - 2' delete input;
followed by
backup archivelog all;
The only problem here is that, if there are no archived logs satisfying until time 'sysdate - 2', the command fails and the rest of the commands in the script are not executed.
I know I could backup all and delete input, but I prefer to have a couple of days' worth available in their original location.
Ideas? Thanks in advance.
Paul Baumgartel
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Fri May 02 2003 - 16:56:56 CDT