User Managed Hot Backup via Sql

Hi being a bit old school - I am trying to understand the steps required for a Hotbackup managed via Sql ( sorry all RMAN fans ! )
I understand that I can backup each tablespace in turn ( via the necessary ALTER TABLESPACE <x> BEGIN BACKUP and then take it out of backup)
I presume also that I simply take a backup of my control file ( wither as binary or as trace if need be )
I am also guessing that you do not backup the Redo Logs ( since you will reset these on any recovery anyway )
The bit I am not sure about is the Undo Tablespace - can it be backup in eactly the same way as any of the other tablespaces ?
Are there any other components that I need to backup ( apart from archive logs )
thanks,
Jim

EdStevens wrote:
Jim Thompson wrote:
Hi being a bit old school - I am trying to understand the steps required for a Hotbackup managed via Sql ( sorry all RMAN fans ! )
I understand that I can backup each tablespace in turn ( via the necessary ALTER TABLESPACE <x> BEGIN BACKUP and then take it out of backup)
I presume also that I simply take a backup of my control file ( wither as binary or as trace if need be )
I am also guessing that you do not backup the Redo Logs ( since you will reset these on any recovery anyway )
The bit I am not sure about is the Undo Tablespace - can it be backup in eactly the same way as any of the other tablespaces ?
Are there any other components that I need to backup ( apart from archive logs )
thanks,
JimI'm old school too. Been in this business over 30 years. Still prefer a command line interface.Me too.
>
But c'mon .... user managed backups? How about dictionary managed tablespaces? initialization parameter files instead of spfiles? Ok, I'll give you the DMT (old skool hippies should be lol now). But user managed backups do have their place, and seriously, I think plain old parameter files are in many cases better than strange binary things that need special software to manipulate and require you to remember arbitrary things. I cuss at regedit every time...
>
What is the business or technical justification for not going with rman?
I can still remember my grandfather arguing with the guy at the tire store, insisting they put inner tubes in those "newfangled" tubeless tires . . .My last lawn tractor had much better luck with tubed replacement tires than tubeless with puncture sealant. Naturally as soon as I bought a new tractor I got a puncture, it doesn't come with sealant. Anyone who's ever struggled with a bead that doesn't set in without a high pressure air pump will appreciate grandpa's point of view. As well as sew-ups.

Similar Messages

  • Which is better for User Managed Hot backup - running in cron or oracle scheduler

    We are taking hot backup in our environment by using sql script of just begin backup, host copy and end backup
    Can we use this script to be put in cron for weekly two times or to use oracle scheduler .
    Which is better option and why?

    The answer to your question depens on your condition. Do you have more experienced Unix admin or DBA?
    From my point of view cron is better becuase all you need is SQL*Plus utility and shell script:
    export ORACLE_SID=...
    sqlplus <username>/<password> as sysdba <<EOF
    ALTER TABLESPACE .. BEGIN BACKUP;
    host copy ..
    ALTER TABLESPACE .. END BACKUP;
    EXIT
    EOF

  • User managed hot backup

    Hi
    When we started a tablespace in begin backup mode state, i know the scn of the datafiles will be blocked and the redo logs generation will be more. I Just want to know when DML activities happen when tablespace in backup mode how the records will get update? why there is no change in SCN? why there is excess redo generation compare to normal DML activitis?
    Venkat

    Venkat,
    Oracle stops recording checkpoints to the datafiles in the tablespace when a tablespace is in backup mode. Because a block can be partially updated at the very moment that the operating system backup utility is copying it, Oracle copies whole changed data blocks into the redo stream while in backup mode. After you take the tablespace out of backup mode with the ALTER TABLESPACE ... END BACKUP or ALTER DATABASE END BACKUP statement, Oracle advances the datafile header to the current database checkpoint.
    When you restore a datafile backed up in this way, the datafile header has a record of the most recent datafile checkpoint that occurred before the online tablespace backup, not any that occurred during it. As a result, Oracle asks for the appropriate set of redo log files to apply should recovery be needed. The redo logs contain all changes required to recover the datafiles and make them consistent.
    So basically no data is inserted in to the datafiles at the time when they are in the backup mode and after they are out of the backup mode, checkpoint is generated and datafiles are updated with the data. Then Ckpt background process update tjhe headers of datafiles and controlfiles with the latest log sequence number.
    Regards,
    Navneet

  • Recovery in R12 with user managed cold backups

    We have R12.1.1 ( db 11.1.0.7 ) on RHEL 5.3 ( ALL SET UP 64 bit ).
    we have user managed cold backup scheduled with tar -czvf command.
    Archiving is enabled. Production server is 2 nodes ( Apps + DB ) .
    Suppose we have backup on hard disk and our Production server ( db is crashed ).
    we will prepare new server copy the backup from Hard disk to new server and run adcfgclone.pl scripts.
    What else do we need to do on this new server to go live ?
    Please reply

    Hi;
    We have R12.1.1 ( db 11.1.0.7 ) on RHEL 5.3 ( ALL SET UP 64 bit ).
    we have user managed cold backup scheduled with tar -czvf command.
    Archiving is enabled. Production server is 2 nodes ( Apps + DB ) .
    Suppose we have backup on hard disk and our Production server ( db is crashed ).
    we will prepare new server copy the backup from Hard disk to new server and run adcfgclone.pl scripts.
    What else do we need to do on this new server to go live ?1. If you run preclone sh before take cold backup than you can go wiht clone process
    2. If you dont run than you can create same user, same mount point on new server and try to relink oracle binary(I assume you have also ORACLE_HOME backup) and try to make up your system
    Regard
    Helios

  • Schedule Hot backup via OEM

    Hello all,
    We have a realtively small system running Oracle 10G on Windows 2003 O/S. I've scheduled a full offiline (cold) backup of the whole db to run once weekly via OEM. Every night we run a script to do a 'logical' backup by EXPORTing the 2 main schemas in the DB out to .DMP files. However this now may not be enough to satisfy DB recovery requirements.
    Is there an easy way to schedule a 'Hot' backup via OEM, that could replace the EXPORT scripts mentioned above, or would we have to write an RMAN script to do this ?? The requirement is really to allow the database to be updateable whilst any daily backup is running. I realise that the DB needs to be in ARCHIVELOG mode for anything like this to work.
    Any advice would be greatly appreciated.
    Thanks,
    Shaun.

    hi,
    on the OEM main page, click on targets, you should see your databse there. click on the database and then on the maintenance tab.
    from here you can schedule jobs and you have the option to schedule a online rman backup of your database. However, to do an online backup your database needs to have archiving turned on. Is this the case as you currently carry out offline backups which might indicate that archiving is turned off.
    regards
    Alan
    Edited by: alanm on Sep 5, 2008 11:47 AM

  • User managed backup

    I am a newbie to Oracle. I am having a question regarding user managed hot backup. My oracle version is 11.2.0.2 and OS version is OEL.
    What will happen, if we perform User Managed Hot Backup without setting tablespaces in BEGIN BACKUP mode?

    aee649c3-9d9a-40a3-bd64-460990851489 wrote:
    I am a newbie to Oracle. I am having a question regarding user managed hot backup. My oracle version is 11.2.0.2 and OS version is OEL.
    What will happen, if we perform User Managed Hot Backup without setting tablespaces in BEGIN BACKUP mode?
    The bigger question is why you would do a user managed backup in the first place.  User managed backup means user managed recovery.  The oracle supplied utility for database backup is 'rman', and the 'r' stand for 'recovery' -- as in "Recovery Manager".  Not using rman to do your backups is akin to not using the spare tire, jack, and lug wrench that came with your car to fix a flat tire.
    ============================================================================
    BTW, it would be really helpful if you would go to your profile and give yourself a recognizable name.  It doesn't have to be your real name, just something that looks like a real name.  Who says my name is really Ed Stevens?  But at least when people see that on a message they have a known identity.  Unlike the system generated name of 'ed0f625b-6857-4956-9b66-da280b7cf3a2', which is like going to the pub with a bag over your head.
    ============================================================================

  • What are the consequences of not backing up controlfile in hot backup.

    Hi All,
    We have 8i,9i, 10g and 11g database. The unfortunate thing is that we are using this user managed hot backups for backing up our database. and I have no idea for what reason, we are not backing up the controlfile. Anyway, I would like you to comment on this, they said, they will recreate a text based controlfile and do the recover database until cancel using backup controlfile ; I know, if we have the path of all the datafiles , we can use this, but is this a right strategy ? of course, no one would agreed on this. I really appriciate, if somone could express his opinion in detail.
    Regards

    Hi,
    The database consists of the following files:
    Spfile/Pfile
    Controlfile
    Datafile
    Redo Log
    archivelog
    When we talk about backing up the database, (no matter how) must take backup up of all these files.
    If you are not taking these files in your backup you have a incomplete backup.
    Why not take a back up of control file to a binary file. Is more simple and fast restore controlfile using binary file.
    ALTER DATABASE BACKUP CONTROLFILE TO '/oracle/backup/control.bkp';To Trace should be used to produce SQL statements that can later be used to re-create your control file.
    ALTER DATABASE BACKUP CONTROLFILE TO TRACE;Why not use RMAN? A resource with endless options and features.
    Using user-managed backup you have none options/feature compared with the use of RMAN.
    It can be used in all Oracle databases without additional license.
    Regards,
    Levi Pereira

  • When to use REUSE/SET, NO-ARCHIVELOGS in create controlfile in HOT BACKUP?

    I am a trainee Oracle DBA and have the following queries. Kindly reply with detailed explanation as I want to get my concepts cleared!
    Q1>> While doing a user managed hot backup, when we are creating a control file(CREATE CONTROLFILE) from trace for recovery when do we use the create control file with the following options:
    *1. REUSE / SET*
    *2. ARCHIVELOGS / NOARCHIVELOGS*
    Q2>> In what scenarios do we re-create the control file while recovering datafiles from a hot backup??
    Thanks a tonne!
    Regards,
    Bhavi

    Hemant K Chitale wrote:
    1.1 It is not "REUSE/SET". These are two very different clauses.
    REUSE is when you want the CREATE to overwrite the existing controlfile(s). If the controlfile(s) {as named in the instance parameter file, initSID.ora or spfileSID.ora} is/are already present, the CREATE fails unless REUSE is specified.
    SET is when you want to change the database name. Oracle then creates the controlfile(s) with the specified database name and updates the headers of all the datafiles. If you run a CREATE with a database name that is different from that in the datafile headers, the CREATE fails unless you include a SET to specify that the name must be changed. Note that this also means that the name in the instance parameter file must already have been updated.
    1.2 ARCHIVELOG/NOARCHIVELOG is to set the database state. The same is achieved by issuing an "ALTER DATABASE ARCHIVELOG/NOARCHIVELOG" when the database is MOUNTed but not OPEN.
    2. You'd run the CREATE CONTROLFILE if you do not have a binary backup of the controlfile.
    Optionally, you can also use CREATE CONTROLFILE to rename all the datafiles by specifying the new locations of the datafiles -- the datafiles must already be present in the new locations, else the CREATE fails if it doesn't find a datafile that is included in the list of datafiles included in the CREATE statement.
    RMAN is the correct way to run Backups. User Managed Backup scripts are used in cases like Storage-based Snapshots / SnapClones / BCV.
    Hemant K ChitaleThanks that was really helpful..One last question when to use the resetlogs/noresetlogs clause in the create controlfile statement. I have noticed that at times it accepts resetlog while at times it accepts noresetlogs

  • Hot backup concept

    Hi,
    i have a doubt in hot backup concept. when we perform hot backup and put the tablespace in begin backup mode the headers are freezed and all the entries for the headers are stored in redlogs. My doubt is if the redolog is archieved will the database applies the entries from archived log on the headers after end backup mode of tablespace???
    Regards,
    007

    Hi,
    i have a doubt in hot backup concept. when we perform hot backup and put the tablespace in begin backup mode the headers are freezed and all the entries for the headers are stored in redlogs. My doubt is if the redolog is archieved will the database applies the entries from archived log on the headers after end backup mode of tablespace??? Putting a tablespace INTO hot backup mode does indeed cause a checkpoint to take place for that tablespace. But when the tablespace is out of hot backup mode does NOT. The SCNs in the headers of that tablespace will re-synchronize next time there is a system-wide checkpoint, but not until then.
    Refer to thread : User managed hot backup
    where HJR provided the demo.
    - Pavan Kumar N
    Edited by: Pavan Kumar on Jul 6, 2011 12:48 AM

  • Hot Backup Validation.

    DB:11.2.0.2
    OS:Linux
    I took a user managed Hot backup of a 120GB database by putting the database in begin backup mode and copied the files to the backup location. How can i validate now that the backup which i took is a valid backup.

    user13549752 wrote:
    DB:11.2.0.2
    OS:Linux
    I took a user managed Hot backup of a 120GB database by putting the database in begin backup mode and copied the files to the backup location. How can i validate now that the backup which i took is a valid backup.First you check to check data file status when you put in "begin backup mode"
    select file#,status from v$backup;Even until unless you restore, recover open you cannot validate them.
    In case of RMAN you can validate. You are talking about 11gR2 what is the reason to choose user managed backup still?

  • Standby hot backup

    Hi all,
    10.2.0
    Do i really need a cold backup for creating a standby database.If i take user managed hot backup and copy it to the stadnby server,wouldn't upon redo apply it would be synchronised and become consistent ?

    Hashmi wrote:
    Hi all,
    10.2.0
    Do i really need a cold backup for creating a standby database.If i take user managed hot backup and copy it to the stadnby server,wouldn't upon redo apply it would be synchronised and become consistent ?Hi,
    Yes you can use hot backup to create standby database?
    Let me know the problem you are facing while creating standby database from hot backup.
    Regards
    Anurag

  • User hot and Rman hot backup

    During user mode hot backup lots of redo gets generated as the entire block is written when any changes are made to a block which is in hot backup mode.But during Rman hot backup less redo are generated why is this so and whatz the logic invloved? and how oracle recovers the file that has been backed up through Rman.
    Could you please explain me regarding this in detail it will be really helpful.
    kumaresh

    From Article      Note:76736.1 RMAN FAQ: Recovery Manager -- Frequently Asked
    To understand why RMAN does not require extra logging or backup mode,
    you must first understand why those features are required for non-RMAN
    online backups.
    A non-RMAN online backup consists of a non-Oracle tool, such as cp or
    dd, backing up a datafile at the same time that DBWR is updating the
    file. We can't prevent the tool from reading a particular block at the
    exact same time that DBWR is updating that block. When that happens,
    the non-Oracle tool might read a block in a half-updated state, so that
    the block which is copied to the backup media might only have been
    updated in its first half, while the second half contains older data.
    This is called a "fractured block". If this backup needs to be restored
    later, and that block needs to be recovered, recovery will fail because
    that block is not usable.
    The 'alter tablespace begin backup' command is our solution for the
    fractured block problem. When a tablespace is in backup mode, and a
    change is made to a data block, instead of logging just the changed
    bytes to the redo log, we also log a copy of the entire block image
    before the change, so that we can reconstruct this block if media
    recovery finds that this block was fractured. That block image logging
    is what causes extra redo to be generated while files are in backup
    mode.
    The reason that RMAN does not require extra logging is that it
    guarantees that it will never back up a fractured block. We can make
    that guarantee because we know the format of Oracle data blocks, and we
    verify that each block that we read is complete before we copy it to the
    backup. If we read a fractured block, we read the block again to obtain
    a complete block before backing it up. non-Oracle tools are not able to
    do the same thing because they do not know how to verify the contents of
    an Oracle data block.
    Backup mode has another effect, which is to 'freeze' the checkpoint in
    the header of the file until the file is removed from backup mode.
    We do this because we cannot guarantee that the third-party backup
    tool will copy the file header prior to copying the data blocks.
    RMAN does not need to freeze the file header checkpoint because we
    know the order in which we will read the blocks, which enables us to
    capture a known good checkpoint for the file.

  • User did an append when doing a backup of SQL now trying to do a restore

    User did a backup of SQL doing an append now getting the message:
    The media set has 2 media families.....
    The directory of the first media set was copied to an external drive.  The system was then wiped to load Win7 what can be done to restore the files?
    Bonnie Whalon

    Hello,
    The command I use was:
    restore filelistonly FROM DISK = N'C:\Freedom Ente\Client Data Backup\Sewickley-fsc-backup-20140403'
    The error message
    Msg 3201, Level 16, State 2, Line 1
    Cannot open backup device 'C:\Freedom Ente\Client Data Backup\Sewickley-fsc-backup-20140403'. Operating system error 5(Access is denied.).Msg 3013, Level 16, State 1, Line 1RESTORE FILELIST is terminating abnormally.
    I gave myself full rights to the directory.
    Bonnie Whalon

  • Where is the official Oracle documentation that describes Hot Backup?

    I have used the woefully inadequate Metalink search utilities and Google but the nearest thing I have found is a description on "Ask Tom".
    I am looking for the official Oracle documentation that describes what happens internally during a Hot Backup. There are a lot of web sites and blogs out there that describe it but I am looking for the description from Oracle themselves. The only things I have found in the Oracle documentation so far is how to start and stop Hot Backup but not what happens internally. Preferably 11gR2 if it makes any difference.
    Thanks in advance.

    Thanks mseberg. This is what I was looking for. I had read this manual before but apparently glossed over this paragraph:
    "When performing a user-managed online backup, you must place your datafiles into
    backup mode with the ALTER DATABASE or ALTER TABLESPACE statement with the
    BEGIN BACKUP clause. When a tablespace is in backup mode, the database writes the
    before image for an entire block to the redo stream before modifying a block. The
    database also records changes to the block in the online redo log. Backup mode also
    freezes the data file checkpoint until the file is removed from backup mode. Oracle
    Database performs this safeguard because it cannot guarantee that a third-party
    backup tool copies the file header before copying the data blocks."
    Hot backup is still quite useful and Rman doesn't cover all cases. What we are doing with it is using storage-based replication (Shadow Image) to another set of LUNS which we then mount on another server and backup using Rman. This removes the overhead of Rman on the Production Database server and extends our backup window to almost 24 hours.

  • Droping and renaming tablespace druing hot user managed backup

    Will dropping and renaming of tablespace will have any effect if hot user managed backup of that db is in progress ?
    thanks in advance

    However, you will encounter a more serious issue because of the way DROP TABLESPACE works.
    Even if the DROP fails, the "INCLUDING CONTENTS" causes all segments to be dropped !!
    SQL> drop table ASSM_TABLE purge;
    Table dropped.
    SQL> create table ASSM_TABLE (pk_col number not null, descr_col  varchar2(30)) tablespace ASSM_TBS;
    Table created.
    SQL> create unique index ASSM_TABLE_PK on ASSM_TABLE (pk_col) tablespace ASSM_TBS;
    Index created.
    SQL> select segment_name, segment_type from user_segments where tablespace_name = 'ASSM_TBS';
    SEGMENT_NAME                   SEGMENT_TYPE
    ASSM_TABLE_PK                  INDEX
    ASSM_TABLE                     TABLE
    SQL> insert into ASSM_TABLE select rownum, 'ABCD ' || rownum from dual connect by level < 10;
    9 rows created.
    SQL> commit;
    Commit complete.
    SQL>
    SQL> connect / as sysdba
    Connected.
    SQL>
    SQL> alter tablespace ASSM_TBS begin backup;
    Tablespace altered.
    SQL> drop tablespace ASSM_TBS including contents and datafiles;
    drop tablespace ASSM_TBS including contents and datafiles
    ERROR at line 1:
    ORA-01150: cannot prevent writes - file 7 has online backup set
    ORA-01110: data file 7:
    'filename'
    SQL> connect hemant/hemant
    Connected.
    SQL> select segment_name, segment_type from user_segments where tablespace_name = 'ASSM_TBS';
    no rows selected
    SQL>  alter tablespace ASSM_TBS end backup
      2  /
    Tablespace altered.
    SQL>The DROP TABLESPACE failed but the contents did get dropped !
    Hemant K Chitale
    Edited by: Hemant K Chitale on Oct 7, 2011 2:41 PM

Maybe you are looking for

  • AE CS6 won't render out my last few clips, error code 1610153464

    Hello, My VFX person finished doing some effects at my house recently and was doing the effects in Adobe After Effects, not through the Dynamic Link. It's about 20 different clips and I rendered out the first 16 one by one with no issues until I came

  • MV45AFZZ USEREXIT_SAVE_DOCUMENT Change VBEP-ETTYP Value

    Greetings,    In VA01/VA02, credit check processing seems to occur after userexit_save_document_prepare leaving me only with userexit_save_document. In userexit_save_document, I am trying to change the schedule line category depending on VBUK-CMGST v

  • My layered menu shows up as white screen!

    I'm working on a 5,9 GB DVD-9 project in DVDSP 4.0.2. The DVD consists of 3 movies and 3 layered menus. The layered menus use a .psd file with up to 7 layers. Nothing fancy, a background and a couple of buttons. The tracks have a couple of stories an

  • What is frame rate with 1920x1080/60p?

    I'm currently shooting and editing HD 1920x1080/60i (interlaced format, 29.97 frames/sec).  To reduce motion artifacts, I'm considering a change in my workflow to HD 1920x1080/60p (progressive format), but first I must update my understanding of this

  • Connecting drop-down with check boxes?

    I am making a document which provides information about retrieving documents for several countries. The user will use this form as a reminder for himself, this way he can see which documents he needs and which documents he still needs to make, or rec