FAQ
About RMAN incremental updated backup, what 's the difference between using
the �until time� clause in RECOVER COPY OF DATABASE and not including this
clause?
As a requirement, the customer is asking the ability to recover the database
to any time within the past 31 days.

We are backing up the fast recovery area to tape every week.

I have read that in the case I am NOT using tape, I have to include the the
�until time� clause in RECOVER COPY OF DATABASE.

Someone can explain me the difference, please?

Here, you can find my backup scripts:

*1- Including the UNTIL TIME clause:*

CONNECT TARGET /

CROSSCHECK BACKUP;

CROSSCHECK ARCHIVELOG ALL;

# Incrementally updated backup.
RECOVER COPY OF DATABASE WITH TAG 'LVL0_MERGE_INCR' UNTIL TIME 'SYSDATE-7';

BACKUP CHECK LOGICAL INCREMENTAL LEVEL 1 CUMULATIVE COPIES=1 FOR RECOVER OF

COPY WITH TAG 'LVL0_MERGE_INCR' DATABASE;

# Switch current logfile to archive
sql 'ALTER SYSTEM ARCHIVE LOG CURRENT';

# Backup archivelogs
BACKUP CHECK LOGICAL AS COMPRESSED BACKUPSET FILESPERSET 10 ARCHIVELOG ALL

DELETE INPUT;

# delete obsolete backups
CROSSCHECK BACKUP;

DELETE NOPROMPT OBSOLETE;

DELETE NOPROMPT EXPIRED BACKUP;

exit;
*
2- NOT Including the UNTIL TIME clause:*

CONNECT TARGET /

CROSSCHECK BACKUP;

CROSSCHECK ARCHIVELOG ALL;

# Incrementally updated backup.
RECOVER COPY OF DATABASE WITH TAG 'LVL0_MERGE_INCR';

BACKUP CHECK LOGICAL INCREMENTAL LEVEL 1 CUMULATIVE COPIES=1 FOR RECOVER OF

COPY WITH TAG 'LVL0_MERGE_INCR' DATABASE;

# Switch current logfile to archive
sql 'ALTER SYSTEM ARCHIVE LOG CURRENT';

# Backup archivelogs
BACKUP CHECK LOGICAL AS COMPRESSED BACKUPSET FILESPERSET 10 ARCHIVELOG ALL

DELETE INPUT;

# delete obsolete backups
CROSSCHECK BACKUP;

DELETE NOPROMPT OBSOLETE;

DELETE NOPROMPT EXPIRED BACKUP;

exit;

Search Discussions

  • Zelli, Brian at Jul 26, 2011 at 6:20 pm
    So I've been putzing around with rman and now I have a list of backups. If I want to restore the very last copy of the db, all I have to do is issue a:

    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7 or 8 listed?

    ciao,
    Brian

    This email message may contain legally privileged and/or confidential information. If you are not the intended recipient(s), or the employee or agent responsible for the delivery of this message to the intended recipient(s), you are hereby notified that any disclosure, copying, distribution, or use of this email message is prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete this email message from your computer. Thank you.
  • Niall Litchfield at Jul 26, 2011 at 8:40 pm
    Essentially yes. You *may* I doubt it in your case not have picked up on the
    distinction of restore (when you need to pull back files from the backups)
    and recovery (application of archived redo). RECOVER will not do the restore
    part - except where archive logs are not on disk, and RESTORE will not do
    the recover bit. So for complete restore and recovery you will need

    RESTORE;

    RECOVER;

    These will use the most recent appropriate available backups (including
    incrementals) to attempt a complete recovery.

    On 26 Jul 2011 19:23, "Zelli, Brian" wrote:

    **
    So I've been putzing around with rman and now I have a list of backups. If
    I want to restore the very last copy of the db, all I have to do is issue a:

    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7 or 8
    listed?

    ciao,

    Brian

    This email message may contain legally privileged and/or confidential
    information. If you are not the intended recipient(s), or the employee or
    agent responsible for the delivery of this message to the intended
    recipient(s), you are hereby notified that any disclosure, copying,
    distribution, or use of this email message is prohibited. If you have
    received this message in error, please notify the sender immediately by
    e-mail and delete this email message from your computer. Thank you.
  • Zelli, Brian at Jul 26, 2011 at 9:40 pm
    Since we don't archive log on this database, I believe a restore will do it. I just took the Oracle 11g admin class part II which dealt with rman but a lot from the em standpoint. Plus we were on windows and the manual was unix. My db's are on unix so I was ok with it. In the past I did mostly unix scripted backups so I am familiar with all things oracle, just not as versed on rman as I wish. Hence the class......... We did practice recovery and restore.

    From: Niall Litchfield [niall.litchfield_at_gmail.com]
    Sent: Tuesday, July 26, 2011 4:40 PM
    To: Zelli, Brian
    Cc: oracle-l@freelists.org
    Subject: Re: rman question

    Essentially yes. You *may* I doubt it in your case not have picked up on the distinction of restore (when you need to pull back files from the backups) and recovery (application of archived redo). RECOVER will not do the restore part - except where archive logs are not on disk, and RESTORE will not do the recover bit. So for complete restore and recovery you will need

    RESTORE;

    RECOVER;

    These will use the most recent appropriate available backups (including incrementals) to attempt a complete recovery.

    On 26 Jul 2011 19:23, "Zelli, Brian" > wrote:

    So I've been putzing around with rman and now I have a list of backups. If I want to restore the very last copy of the db, all I have to do is issue a:

    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7 or 8 listed?

    ciao,
    Brian

    This email message may contain legally privileged and/or confidential information. If you are not the intended recipient(s), or the employee or agent responsible for the delivery of this message to the intended recipient(s), you are hereby notified that any disclosure, copying, distribution, or use of this email message is prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete this email message from your computer. Thank you.

    This email message may contain legally privileged and/or confidential information. If you are not the intended recipient(s), or the employee or agent responsible for the delivery of this message to the intended recipient(s), you are hereby notified that any disclosure, copying, distribution, or use of this email message is prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete this email message from your computer. Thank you.--
    http://www.freelists.org/webpage/oracle-l
  • Chitale, Hemant Krishnarao at Jul 27, 2011 at 2:48 am
    If you don't have ARCHIVELOG mode, all your backups are "Consistent"
    backups made when the database is MOUNTed but not OPEN.

    Your restore and recovery scenario practice must also include the case
    where you have also lost the controlfile. How you restore the
    controlfile depends on how you backup (or autobackup) the controlfile.
    The controlfile must be available and database MOUNTed before you can do
    a RESTORE DATABASE.

    (of course the final question is : WHY you don't have ARCHIVELOG mode
    enabled ? there are situations where a database is left in NOARCHIVELOG
    mode but that must be a conscious decision after understanding all the
    ramifications).



    Hemant K Chitale
    -----Original Message-----
    From: oracle-l-bounce_at_freelists.org
    On Behalf Of Zelli, Brian
    Sent: Wednesday, July 27, 2011 5:41 AM
    To: Niall Litchfield
    Cc: oracle-l@freelists.org
    Subject: RE: rman question

    Since we don't archive log on this database, I believe a restore will do
    it. I just took the Oracle 11g admin class part II which dealt with
    rman but a lot from the em standpoint. Plus we were on windows and the
    manual was unix. My db's are on unix so I was ok with it. In the past
    I did mostly unix scripted backups so I am familiar with all things
    oracle, just not as versed on rman as I wish. Hence the class.........
    We did practice recovery and restore.

    From: Niall Litchfield [niall.litchfield_at_gmail.com]
    Sent: Tuesday, July 26, 2011 4:40 PM
    To: Zelli, Brian
    Cc: oracle-l@freelists.org
    Subject: Re: rman question

    Essentially yes. You *may* I doubt it in your case not have picked up on
    the distinction of restore (when you need to pull back files from the
    backups) and recovery (application of archived redo). RECOVER will not
    do the restore part - except where archive logs are not on disk, and
    RESTORE will not do the recover bit. So for complete restore and
    recovery you will need

    RESTORE;

    RECOVER;

    These will use the most recent appropriate available backups (including
    incrementals) to attempt a complete recovery.

    On 26 Jul 2011 19:23, "Zelli, Brian"
    wrote:
    So I've been putzing around with rman and now I have a list of backups.
    If I want to restore the very last copy of the db, all I have to do is
    issue a:

    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7
    or 8 listed?

    ciao,
    Brian

    This email and any attachments are confidential and may also be privileged. If you are not the addressee, do not disclose, copy, circulate or in any other way use or rely on the information contained in this email or any attachments. If received in error, notify the sender immediately and delete this email and any attachments from your system. Emails cannot be guaranteed to be secure or error free as the message and any attachments could be intercepted, corrupted, lost, delayed, incomplete or amended. Standard Chartered PLC and its subsidiaries do not accept liability for damage caused by this email or any attachments and may monitor email traffic.

    Standard Chartered PLC is incorporated in England with limited liability under company number 966425 and has its registered office at 1 Aldermanbury Square, London, EC2V 7SB.

    Standard Chartered Bank ("SCB") is incorporated in England with limited liability by Royal Charter 1853, under reference ZC18. The Principal Office of SCB is situated in England at 1 Aldermanbury Square, London EC2V 7SB. In the United Kingdom, SCB is authorised and regulated by the Financial Services Authority under FSA register number 114276.

    If you are receiving this email from SCB outside the UK, please click http://www.standardchartered.com/global/email_disclaimer.html to refer to the information on other jurisdictions.
  • Robert Freeman at Jul 26, 2011 at 11:11 pm
    So, forgive the book plug but my RMAN book is a great "how-to" guide on getting
    started with RMAN. It walks you through various workshops from setting up, to
    backing up to restoring the database. It's available on Amazon (Oracle 11g RMAN
    Backup and Recovery from Oracle Press) and is reasonably priced.

    As an aside, I'm looking to start a new book on Oracle Golden Gate..... Should
    be fun!

    Cheers!

    Robert G. Freeman
    Master Principal Consultant, Oracle Corporation, Oracle ACE
    Author of various books on RMAN, New Features and this shorter signature line.
    Blog: http://robertgfreeman.blogspot.com

    Note: THIS EMAIL IS NOT AN OFFICIAL ORACLE SUPPORT COMMUNICATION. It is just the
    opinion of one Oracle employee. I can be wrong, have been wrong in the past and
    will be wrong in the future. If your problem is a critical production problem,
    you should always contact Oracle support for assistance. Statements in this
    email in no way represent Oracle Corporation or any subsidiaries and reflect
    only the opinion of the author of this email.

    From: "Zelli, Brian"
    To: "oracle-l@freelists.org"
    Sent: Tue, July 26, 2011 12:20:57 PM
    Subject: rman question

    So I've been putzing around with rman and now I have a list of backups. If I
    want to restore the very last copy of the db, all I have to do is issue a:



    RMAN> recover database;


    that's it? And it will take that last copy even though I have about 7 or 8
    listed?


    ciao,
    Brian


    This email message may contain legally privileged and/or confidential
    information. If you are not the intended recipient(s), or the employee or agent
    responsible for the delivery of this message to the intended recipient(s), you
    are hereby notified that any disclosure, copying, distribution, or use of this
    email message is prohibited. If you have received this message in error, please
    notify the sender immediately by e-mail and delete this email message from your
    computer. Thank you.
  • Anonymous at Jul 26, 2011 at 6:36 pm
    Brian,

    Essentially yes.

    It knows about all the backups. It knows the state of the current database.

    You are not describing your test case well enough to give a fuller answer.

    Did you lose a data file? A couple of data files? The entire database including control files?

    If I were you ( and I've done this), I would create a test database and go through recovery scenarious.

    Delete a data file and write the Rman script to restore and recover it.
    Delete a couple of data files and do the same.
    Delete the entire database including control files.
    Perform an incomplete (point in time) recovery of one tablespace.
    Roll a database back to a prior point in time.

    Get the idea?

    Tom

    From: oracle-l-bounce_at_freelists.org On Behalf Of Zelli, Brian
    Sent: Tuesday, July 26, 2011 2:21 PM
    To: 'oracle-l@freelists.org'
    Subject: rman question

    So I've been putzing around with rman and now I have a list of backups. If I want to restore the very last copy of the db, all I have to do is issue a:

    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7 or 8 listed?

    ciao,
    Brian

    This email message may contain legally privileged and/or confidential information. If you are not the intended recipient(s), or the employee or agent responsible for the delivery of this message to the intended recipient(s), you are hereby notified that any disclosure, copying, distribution, or use of this email message is prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete this email message from your computer. Thank you.
  • Andrew Kerber at Jul 26, 2011 at 6:48 pm
    Brian-
    If you work, or plan to work, as a professional DBA, I strongly recommend
    you be familiar with all the scenarios that Thomas describes. At various
    times I have run into all those scenarios.

    As others have noted in the past, backup and recovery is where DBA's earn
    their pay (and can lose their job for that matter).

    On Tue, Jul 26, 2011 at 1:36 PM, Mercadante, Thomas F (LABOR) <
    Thomas.Mercadante_at_labor.ny.gov> wrote:
    Brian,****


    Essentially yes.****

    ** **

    It knows about all the backups. It knows the state of the current
    database. ****

    ** **

    You are not describing your test case well enough to give a fuller answer.
    ****

    ** **

    Did you lose a data file? A couple of data files? The entire database
    including control files?****

    ** **

    If I were you ( and I�ve done this), I would create a test database and go
    through recovery scenarious.****

    ** **

    Delete a data file and write the Rman script to restore and recover it.***
    *

    Delete a couple of data files and do the same.****

    Delete the entire database including control files.****

    Perform an incomplete (point in time) recovery of one tablespace.****

    Roll a database back to a prior point in time.****

    ** **

    Get the idea?****

    ** **

    Tom****

    ** **

    ** **

    *From:* oracle-l-bounce_at_freelists.org [mailto:
    oracle-l-bounce@freelists.org] *On Behalf Of *Zelli, Brian
    *Sent:* Tuesday, July 26, 2011 2:21 PM
    *To:* 'oracle-l@freelists.org'
    *Subject:* rman question****

    ** **

    So I've been putzing around with rman and now I have a list of backups. If
    I want to restore the very last copy of the db, all I have to do is issue a:
    ****

    ****

    RMAN> recover database;****

    ****

    that's it? And it will take that last copy even though I have about 7 or 8
    listed?****

    ****

    ciao,****

    Brian****

    ****


    This email message may contain legally privileged and/or confidential
    information. If you are not the intended recipient(s), or the employee or
    agent responsible for the delivery of this message to the intended
    recipient(s), you are hereby notified that any disclosure, copying,
    distribution, or use of this email message is prohibited. If you have
    received this message in error, please notify the sender immediately by
    e-mail and delete this email message from your computer. Thank you. ****
    --
    Andrew W. Kerber

    'If at first you dont succeed, dont take up skydiving.'

    --
    http://www.freelists.org/webpage/oracle-l
  • Robert Freeman at Jul 26, 2011 at 11:12 pm
    Amen.....

    I can provide case after case after case where people did not understand and
    properly configure their backup and recovery architecture.... and disaster
    resulted. It is, job #1. If there is no data, there is no need for a database,
    tuning, replication, PL/SQL or any of that other cool stuff people love to do.

    Cheers

    RF

    Robert G. Freeman
    Master Principal Consultant, Oracle Corporation, Oracle ACE
    Author of various books on RMAN, New Features and this shorter signature line.
    Blog: http://robertgfreeman.blogspot.com

    Note: THIS EMAIL IS NOT AN OFFICIAL ORACLE SUPPORT COMMUNICATION. It is just the
    opinion of one Oracle employee. I can be wrong, have been wrong in the past and
    will be wrong in the future. If your problem is a critical production problem,
    you should always contact Oracle support for assistance. Statements in this
    email in no way represent Oracle Corporation or any subsidiaries and reflect
    only the opinion of the author of this email.

    ________________________________
    From: Andrew Kerber
    To: Thomas.Mercadante_at_labor.ny.gov
    Cc: "Brian.Zelli_at_RoswellPark.org";
    "oracle-l@freelists.org"
    Sent: Tue, July 26, 2011 12:48:56 PM
    Subject: Re: rman question

    Brian-
    If you work, or plan to work, as a professional DBA, I strongly recommend you be
    familiar with all the scenarios that Thomas describes. At various times I have
    run into all those scenarios.

    As others have noted in the past, backup and recovery is where DBA's earn their
    pay (and can lose their job for that matter).

    On Tue, Jul 26, 2011 at 1:36 PM, Mercadante, Thomas F (LABOR)
    wrote:

    Brian,
    Essentially yes.

    It knows about all the backups. It knows the state of the current database.

    You are not describing your test case well enough to give a fuller answer.

    Did you lose a data file? A couple of data files? The entire database
    including control files?

    If I were you ( and I’ve done this), I would create a test database and go
    through recovery scenarious.

    Delete a data file and write the Rman script to restore and recover it.
    Delete a couple of data files and do the same.
    Delete the entire database including control files.
    Perform an incomplete (point in time) recovery of one tablespace.
    Roll a database back to a prior point in time.

    Get the idea?

    Tom


    From:oracle-l-bounce_at_freelists.org On
    Behalf Of Zelli, Brian
    Sent: Tuesday, July 26, 2011 2:21 PM
    To: 'oracle-l@freelists.org'
    Subject: rman question

    So I've been putzing around with rman and now I have a list of backups. If I
    want to restore the very last copy of the db, all I have to do is issue a:


    RMAN> recover database;

    that's it? And it will take that last copy even though I have about 7 or 8
    listed?

    ciao,
    Brian


    This email message may contain legally privileged and/or confidential
    information. If you are not the intended recipient(s), or the employee or agent
    responsible for the delivery of this message to the intended recipient(s), you
    are hereby notified that any disclosure, copying, distribution, or use of this
    email message is prohibited. If you have received this message in error, please
    notify the sender immediately by e-mail and delete this email message from your
    computer. Thank you.
    --
    Andrew W. Kerber

    'If at first you dont succeed, dont take up skydiving.'

    --
    http://www.freelists.org/webpage/oracle-l
  • Chitale, Hemant Krishnarao at Jul 27, 2011 at 2:44 am
    Since Brian also says, in a subsequent email :



    "I just took the Oracle 11g admin class part II which dealt with rman
    but a lot from the em standpoint. Plus we were on windows and the
    manual was unix."



    Oracle University OR the instructor at Oracle University isn't doing a
    good job.



    Hemant K Chitale

    From: oracle-l-bounce_at_freelists.org
    On Behalf Of Andrew Kerber
    Sent: Wednesday, July 27, 2011 2:49 AM
    To: Thomas.Mercadante_at_labor.ny.gov
    Cc: Brian.Zelli_at_RoswellPark.org; oracle-l@freelists.org
    Subject: Re: rman question



    Brian-
    If you work, or plan to work, as a professional DBA, I strongly
    recommend you be familiar with all the scenarios that Thomas describes.
    At various times I have run into all those scenarios.

    As others have noted in the past, backup and recovery is where DBA's
    earn their pay (and can lose their job for that matter).

    Andrew W. Kerber

    'If at first you dont succeed, dont take up skydiving.'

    This email and any attachments are confidential and may also be privileged. If you are not the addressee, do not disclose, copy, circulate or in any other way use or rely on the information contained in this email or any attachments. If received in error, notify the sender immediately and delete this email and any attachments from your system. Emails cannot be guaranteed to be secure or error free as the message and any attachments could be intercepted, corrupted, lost, delayed, incomplete or amended. Standard Chartered PLC and its subsidiaries do not accept liability for damage caused by this email or any attachments and may monitor email traffic.

    Standard Chartered PLC is incorporated in England with limited liability under company number 966425 and has its registered office at 1 Aldermanbury Square, London, EC2V 7SB.

    Standard Chartered Bank ("SCB") is incorporated in England with limited liability by Royal Charter 1853, under reference ZC18. The Principal Office of SCB is situated in England at 1 Aldermanbury Square, London EC2V 7SB. In the United Kingdom, SCB is authorised and regulated by the Financial Services Authority under FSA register number 114276.

    If you are receiving this email from SCB outside the UK, please click http://www.standardchartered.com/global/email_disclaimer.html to refer to the information on other jurisdictions.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouporacle-l @
categoriesoracle
postedJul 13, '11 at 7:41a
activeJul 27, '11 at 2:48a
posts10
users7
websiteoracle.com

People

Translate

site design / logo © 2022 Grokbase