Tablespace and datafile hot backup

Hello

I wanted to if there is a command to copy a data file using the sqlplus command. I made a script that backs up the database while its online. I made a script for the alter tablespace begin backup, but I wanted to know how to copy the data files without using the OS command, instead, I wanted to use a sql commands. Is there any script or procedure to do this one.


Thank you

Best regards
Audrey

Hi you can do it from windows sqlplus

If you are using windows try this

alter tablespace users begin backup;
ocopy I:\USERS01 of the host. DBF C:\hotdump\
alter tablespace users end backup;

If you use Linux use suite

alter tablespace users begin backup;
! / u01/oradata/USERS01 cp. DBF/U02/hotdump /.
alter tablespace users end backup;

Tags: Database

Similar Questions

  • excluding tablespace in the hot backup

    Hi master,

    I use oracle 10g on linux. We use the hot backup to date strategy to back up the database.


    but I think that I support too much data. I now have tablespeces in my database

    System
    users
    Temp
    Cancel
    index
    perfstat
    blob1
    tool
    etc. and default tablespace installed by oracle at installation time.

    I can I exclude some of the hot backup table spaces so that it consumes less time to back up the database?


    can I exclude spaces of temp, perstat and tool table?

    It will cause no impact on the database and?

    Thanks and greetings
    VD

    DON'T think to drop your UNDO tablespace. You use it to save "in front of your block images.
    Re: cancel

  • UNDOTABLESPACE and TABLESPACE TEMP in cold or hot backup database

    Hello

    I have a BACKUP, including logs generated after the backup archive. What is the use of the UNDOTABLESPACE and TABLESPACE TEMP datafile data file backup? When it is used?


    Kind regards

    007

    >
    I have the archives which have all entries are committed in it. Undoinformation is necessary for the restoration and recovery of the database? Can u explain more clearly?
    >

    The archives are as congested entries of redo logs. And the redo logs contain all changes to the database. Information cancellation will be there in the segments of cancellation that there can be some uncommitted transactions active in the segments of cancellation. Cancellation information is necessary to put the database in a consistent state. It is one of very important storage similar to the control file and system tablespace to bring a database

    Edited: Imagine a scenario. You make a backup hot at 07:00. And there are a lot of transactions happening before and during hot backup. For ex, I run a massive update to a table. This will cause the recovery to write logs of recovery that will be eventually written to logs archived. Now, you finish the backup mode. But I have not validated or cancelled my transaction. Say to the reasoning, I roll back the transaction.

    Now, you restore the backup. Do you think that my transaction will be in inconsistent state? Redo logs and archiveed newspapers had my transaction changes/redo entries. If you are not using undo in recovery segments, what will happen to my operation that I rolled back? Without cancel, half of my transaction (even if they were not truly committed) will be sitting in the database. This is where undo tablespace helps us in rolling back the transaction during your recovery. Remember, the cancellation information "peuvent" not all in recovery if you do not a complete database recovery. But Oracle should know that. If you need to undo tablespace in your backup set.

    I hope it's clear now

    Published by: VenkatB on Sep 15, 2011 10:17

  • archivelog mode and hot backup

    Hello
    in g R2
    This is the hot backup:
    online backup
    
    A backup of one or more datafiles taken while a database is open and the datafiles are online. 
    When you make a user-managed backup while the database is open, you must put the 
    tablespaces in backup mode by issuing an ALTER TABLESPACE BEGIN BACKUP command. 
    (You can also use ALTER DATABASE BEGIN BACKUP to put all tablespaces in your database into backup mode in one step.)
    would we in log mode archive to do an online backup?

    Thank you.

    user522961 wrote:
    Hello
    in g R2
    This is the hot backup:

    would we in log mode archive to do an online backup?

    Yes. It is a must!

    HTH
    Aman...

  • VCB Helper for SCSI Hot-add and FULL-VM backups

    Hello

    I would just ask all those who are already using the computer virtual configured as a helper of the VCB for SCSI Hot-add if it can be used to make the full-VM image-level backups?

    We currently use a physical VCB server to make the backups weekly full-vm image via the SAN with a backup agent software to capture the day-to-day changes.

    As part of our current DR, let's use SRM and the Faculty linked VCB a VM and reduce the number of physical servers, we need to reproduce the site of DR looks tempting.

    Look forward to your responses,

    Craig.

    Craig-

    First of all, welcome to the Forums!

    To answer your questuion, Yes, running VCB in addition to hot mode supports FullVM-level backups and file. However, the SAN mode is the most effective way to backup of virtual machines.

    Think about why you are replicating your data center: for a fast recovery. If all virtual machines are replicated, there should be no need to restore from a full site FullVM disaster backup. With replication, VCB and agent of the base backups are recovering after a local disaster, as a virtual machine crashing or someone deleting a file (or even a virtual machine). It is also for archival purposes.

    Once you have recovered from a disaster, the VERY next step should be to make a clean backup, so VCB is required on the site of DR. If you are looking to reduce the material on the site of DR, make the VCB proxy and the server vCenter one machine virtual on the DR site, but let the VCB as a medical examination on your production site. The end result will be FullVM backups via SAN to a physical server and ' rescue' VCB proxy in a virtual machine on the site of DR.

    As a warning and to add to your confusion: o), some people find that hot add mode is faster than the SAN mode, depending on the setting of the physical server VCB and SAN...

    You can also study the esXpress, allowing you to perform backups on a VMFS volume. This could be replicated to your recovery site and serve your backup off site location.

    Dave Convery - VMware vExpert 2009

    ************************

    Accomplish the impossible only means that the boss will add it to your regular tasks.

    Doug Larson

  • Is there a difference between a Hot Backup and online backup?

    Version: 10 g 2

    Is there a difference between a Hot Backup and online backup? These terms are not interchangeably used? Could not find a wire similair in OTN.

    Yes, these terms are used interchangeably.

  • HOT backup database 10g express edition

    Dear Sir
    I use oracle database 10g express edition with 3.2.1 apex.

    I'm planing to db.here hot backup entire database is 24 x 7 running... fashion archive
    Info

    pFile, control, password file
    System datafile
    SYSAUX datafile
    Undo tablespace file
    temporary tablespace file
    redo log files
    application data tablespace file
    application index tablespace file

    for backup of the entire database HOT including apex WORKSPACE... which tablespace or files are REQUIRED for backup?

    Thank you
    Engr.M.K Chowdhury

    Hello

    To be convinced, you can do the following:

    alter database begin backup;
    

    Then, you check the backup status of your datafilles with the following query:

    select file#, status
    from v$backup
    order by file#;
    

    If the status is ACTIVE, this means that the data files are in backup mode, and you can copy them.

    The redologs online, you can save them but this is not mandatory, because you have logs archived.

    It is important to get all archived logs generated during (and after) the backup.

    To do this, you can run the following right after the hot data files backup:

    alter system archive log current;
    

    It will generate a log archived that you need to include in your backup.

    If you lose all your data (including the redologs online), after you restore the data files, you need to retrieve
    the database. During this operation, you apply all archived logs and then you reset the redologs. It is a
    incomplete recovery.

    However, for the online redo logs, it is important to multiplex to another disk. So, if you lose members on
    a single disk, you can perform a full restore with their copy on the second disc.

    Hope this helps.
    Best regards
    Jean Valentine

  • Drop tablespace and flashback: ORA-01245: offline file 7 will be lost if RESETLOGS is done

    Hello

    1. create tablespace TS1
    2. create restore RP1 point;
    3 drop tablespace TS1 (datafile ' / c:/ts1.dbf ') including files
    4 restore database to RP1
    5 alter database open resetlogs failed with this error:
    ERROR on line 1:
    ORA-01245: offline file 7 will be lost if RESETLOGS is done
    ORA-01110: data file 7: ' / c:/ts1.dbf '

    Can you help me please to solve this problem and to understand why it happened.

    Hello

    If you check the log of alerts you will get message similar to

    Remove the #7 file recovery:'/db/dbs/UNNAMED00007 ' of controlfile.

    Now you have 2 possible

    1. If you have backup of the tablespace TS1, then you can restore and recover

    If you do not need this tablespace then you drop that datafile offline 7. Open the database in resetlogs mode and drop the tablespace TS1

    Thank you

  • Hot backup

    We take the backup hot at 18:00 (daily, filled in 1-2 hours).
    At 23:30 all archive log files will be separately BackupExec backup and the log files are deleted from the file archive of the Oracle.

    Day before yesterday, for some reason, the copy of the data file hung up (after alter database begin backup has been published in the Hot backup script)
    That the copy has been hung up, 'alter database end backup' has been issued, the PB was in backup mode.
    The average while the deleted BackupExec database journal archive file Archive of the Oracle.

    Yesterday hot backup was completed successfully, only alter database begin backup failed (ORA-01146: cannot start online backup - folder 1 is already in the backup)
    After the hot backup 'alter database end backup' was published successfully.

    Given that logs archiving failed whien database is always in backup mode, will all the data generated duing the applied to the data file backup mode?

    Please notify.

    Thanks in advance,

    Arul

    You hear all changes (including the dml, ddl) applied to the database during the backup mode...

    YES.
    See http://www.bluegecko.net/oracle/oracle-tablespace-hot-backup-mode-revisited/

    Hemant K Collette

  • How to Setup Data Guard with alter tablespace... begin backup approach

    Hello!

    I am writing this compilation of documents in a guard daata establishing in 10g. I was in charge to present different approaches in implementing on Rhel 5.

    I came across 3 procedures (which is to duplicate a database with RMAN, then configure it to a Data Guard feature). I read a process using (let's this is what the article said, but procedure was presented):

    alter tablespace... .begin backup;
    alter tablespace... .end backup;

    then copy the generated files and configure it to the data protection feature.

    Someone help it with that? Is there like a blogsite or steps I can take for this scenario?

    Hello;

    The best I found was: (and its same 10 Oracle! and not RMAN.)

    http://sites.Google.com/site/catchdba/physical-standby-database-using-HOTBackup

    There, an old link here on this topic:

    DataGuard configuration using hot backup files

    Hard to find much on this topic as "Hot Backup" almost always comes to RMAN.

    This collection of notes can also help:

    DataGuard knowledge browser Product Page [ID 267955.1]

    And the "Formidable" Powerpoint:

    www.dbspecialists.com/files/presentations/standbydb.ppt

    Seems that this method is dead somewhere between Oracle 8 and Oracle 9

    Best regards

    mseberg

    Published by: mseberg on March 16, 2012 20:31

  • lost control file and datafile addeed restore/recovery without loss of data

    Here, I tried the following

    created a new table called t2 and made sure the data went to a specific tablespace...
    has taken a level 0 backup
    remove the control file
    couple of datafile to above tablespace was added and then insert more data
    then went out to restore the database... but datafile and control file always could not be open? What is wrong here...

    SQL> @datafile
    -- list of datafile
    
    Tablespace File Typ Tablespac File Stat    Used MB    Free MB    FILE_MB    MAXMB Datafile_name                     FILE_ID AUT
    ---------- -------- --------- --------- ---------- ---------- ---------- -------- ------------------------------ ---------- ---
    UNDOTBS1   Datafile ONLINE    AVAILABLE         16         84        100    1,024 /data/trgt/undotbs01.dbf                3 YES
    USERS      Datafile ONLINE    AVAILABLE       1153        895       2048    3,072 /data3/trgt/user02.dbf                  5 YES
    CNT_TST    Datafile ONLINE    AVAILABLE          1          9         10        0 /data3/trgt/cnt_tst01.dbf               7 NO
    SYSAUX     Datafile ONLINE    AVAILABLE        626         35        660   32,768 /data/trgt/sysaux01.dbf                 2 YES
    USERS      Datafile ONLINE    AVAILABLE       2031         17       2048    2,048 /data3/trgt/move/users01.dbf            4 YES
    SYSTEM     Datafile ONLINE    AVAILABLE        712         58        770   32,768 /data/trgt/system01.dbf                 1 YES
    USERS      Datafile ONLINE    AVAILABLE         65         35        100   32,768 /data3/trgt/users03.dbf                 6 YES
    
    7 rows selected.
    -- new table is created called t2 and its going into TS called cnt_tst
    SQL> CREATE TABLE TEST.T2
    (
      C1  DATE,
      C2  NUMBER,
      C3  NUMBER,
      C4  VARCHAR2(300 BYTE)
    )
    TABLESPACE cnt_tst;  2    3    4    5    6    7    8
    
    Table created.
    -- data inserted
    SQL> INSERT INTO
      test.T2
    SELECT
      *
    FROM
      (SELECT
        SYSDATE,
        ROWNUM C2,
        DECODE(MOD(ROWNUM,100),99,99,1) C3,
        RPAD('A',300,'A') C4
      FROM
        DUAL
      CONNECT BY
        LEVEL <= 10000)
    ;   2    3    4    5    6    7    8    9   10   11   12   13   14   15
    
    10000 rows created.
    
    SQL> commit;
    
    Commit complete.
    -- to check of cnt_tst has any free space or not, as we can see its full
    SQL> @datafile
    
    Tablespace File Typ Tablespac File Stat    Used MB    Free MB    FILE_MB    MAXMB Datafile_name                     FILE_ID AUT
    ---------- -------- --------- --------- ---------- ---------- ---------- -------- ------------------------------ ---------- ---
    UNDOTBS1   Datafile ONLINE    AVAILABLE         16         84        100    1,024 /data/trgt/undotbs01.dbf                3 YES
    USERS      Datafile ONLINE    AVAILABLE       1153        895       2048    3,072 /data3/trgt/user02.dbf                  5 YES
    SYSAUX     Datafile ONLINE    AVAILABLE        626         35        660   32,768 /data/trgt/sysaux01.dbf                 2 YES
    USERS      Datafile ONLINE    AVAILABLE       2031         17       2048    2,048 /data3/trgt/move/users01.dbf            4 YES
    SYSTEM     Datafile ONLINE    AVAILABLE        712         58        770   32,768 /data/trgt/system01.dbf                 1 YES
    USERS      Datafile ONLINE    AVAILABLE         65         35        100   32,768 /data3/trgt/users03.dbf                 6 YES
    CNT_TST    Datafile ONLINE    AVAILABLE         10          0         10        0 /data3/trgt/cnt_tst01.dbf               7 NO
    
    7 rows selected.
    
    SQL> select count(*) from test.t2;
    
      COUNT(*)
    ----------
         10000
    
    1 row selected.
    -- to get a count and max on date
    SQL> select max(c1) from test.t2;
    
    MAX(C1)
    ------------------
    29-feb-12 13:47:52
    
    1 row selected.
    
    SQL> -- AT THIS POINT A LEVEL 0 BACKUP IS TAKEN (using backup database plus archivelog)
    SQL> -- now control files are removed
    SQL> select name from v$controlfile;
    
    NAME
    --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    /ctrl/trgt/control01.ctl
    /ctrl/trgt/control02.ctl
    
    2 rows selected.
    
    SQL>
    SQL> ! rm /ctrl/trgt/control01.ctl
    SQL> ! rm /ctrl/trgt/control02.ctl
    SQL> ! ls -ltr /ctrl/trgt/
    
    ls: /ctrl/trgt/: No such file or directory
    
    SQL> 
    -- new datafile is added to CNT_TST TABLESPACE and new data is added as well
    SQL> ALTER TABLESPACE CNT_TST ADD DATAFILE '/data3/trgt/CNT_TST02.dbf' SIZE 100M AUTOEXTEND OFF;
    
    Tablespace altered.
    
    SQL> ALTER SYSTEM CHECKPOINT;
    
    System altered.
    
    SQL> alter system switch logfile;
    
    System altered.
    
    SQL> /
    
    System altered.
    
    SQL> /
    
    System altered.
    
    SQL> ALTER TABLESPACE CNT_TST ADD DATAFILE '/data3/trgt/CNT_TST03.dbf' SIZE 100M AUTOEXTEND OFF;
    
    Tablespace altered.
    
    SQL>  INSERT INTO
      test.T2
    SELECT
      *
    FROM
      (SELECT
        SYSDATE,
        ROWNUM C2,
        DECODE(MOD(ROWNUM,100),99,99,1) C3,
        RPAD('A',300,'A') C4
      FROM
        DUAL
      CONNECT BY
        LEVEL <= 10000)
    ;   2    3    4    5    6    7    8    9   10   11   12   13   14   15
    
    10000 rows created.
    
    SQL> /
    
    10000 rows created.
    
    SQL> commit;
    
    Commit complete.
    
    SQL> INSERT INTO
      test.T2
    SELECT
      *
    FROM
      (SELECT
        SYSDATE,
        ROWNUM C2,
        DECODE(MOD(ROWNUM,100),99,99,1) C3,
        RPAD('A',300,'A') C4
      FROM
        DUAL
      CONNECT BY
        LEVEL <= 40000)
    ;  2    3    4    5    6    7    8    9   10   11   12   13   14   15
    
    40000 rows created.
    
    SQL> commit;
    
    Commit complete.
    
    SQL> @datafile
    -- to make sure new datafile has been registered with the DB 
    Tablespace File Typ Tablespac File Stat    Used MB    Free MB    FILE_MB    MAXMB Datafile_name                     FILE_ID AUT
    ---------- -------- --------- --------- ---------- ---------- ---------- -------- ------------------------------ ---------- ---
    CNT_TST    Datafile ONLINE    AVAILABLE          9         91        100        0 /data3/trgt/CNT_TST03.dbf               9 NO
    UNDOTBS1   Datafile ONLINE    AVAILABLE         16         84        100    1,024 /data/trgt/undotbs01.dbf                3 YES
    USERS      Datafile ONLINE    AVAILABLE       1153        895       2048    3,072 /data3/trgt/user02.dbf                  5 YES
    CNT_TST    Datafile ONLINE    AVAILABLE          9         91        100        0 /data3/trgt/CNT_TST02.dbf               8 NO
    SYSAUX     Datafile ONLINE    AVAILABLE        626         35        660   32,768 /data/trgt/sysaux01.dbf                 2 YES
    USERS      Datafile ONLINE    AVAILABLE       2031         17       2048    2,048 /data3/trgt/move/users01.dbf            4 YES
    SYSTEM     Datafile ONLINE    AVAILABLE        712         58        770   32,768 /data/trgt/system01.dbf                 1 YES
    USERS      Datafile ONLINE    AVAILABLE         65         35        100   32,768 /data3/trgt/users03.dbf                 6 YES
    CNT_TST    Datafile ONLINE    AVAILABLE         10          0         10        0 /data3/trgt/cnt_tst01.dbf               7 NO
    
    9 rows selected.
    -- now the count and max ... note count before backup was 10000 and max(c1) was diff
    SQL> select count(*) from test.t2;
    
      COUNT(*)
    ----------
         70000
    
    1 row selected.
    
    SQL> select max(c1) from test.t2;
    
    MAX(C1)
    ------------------
    29-feb-12 13:58:25
    
    1 row selected.
    
    SQL> -- now restore starts 
    SQL> shutdown abort;
    ORACLE instance shut down.
    SQL> exit
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    [oracle@berry trgt]$ rman
    
    Recovery Manager: Release 11.2.0.1.0 - Production on Wed Feb 29 14:01:48 2012
    
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    
    RMAN>  connect catalog rman/pass@rcat
    
    connected to recovery catalog database
    
    RMAN>  connect target /
    
    connected to target database (not started)
    
    RMAN> startup nomount;
    
    Oracle instance started
    
    Total System Global Area     188313600 bytes
    
    Fixed Size                     1335388 bytes
    Variable Size                125833124 bytes
    Database Buffers              58720256 bytes
    Redo Buffers                   2424832 bytes
    
    RMAN> restore controlfile from autobackup;
    
    Starting restore at 29-FEB-12 14:02:37
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=20 device type=DISK
    
    recovery area destination: /backup/trgt/flash_recovery_area
    database name (or database unique name) used for search: TRGT
    channel ORA_DISK_1: no AUTOBACKUPS found in the recovery area
    channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120229
    channel ORA_DISK_1: AUTOBACKUP found: /backup/trgt/backup/cont_c-3405317011-20120229-09
    channel ORA_DISK_1: restoring control file from AUTOBACKUP /backup/trgt/backup/cont_c-3405317011-20120229-09
    channel ORA_DISK_1: control file restore from AUTOBACKUP complete
    output file name=/ctrl/trgt/control01.ctl
    output file name=/ctrl/trgt/control02.ctl
    Finished restore at 29-FEB-12 14:02:39
    
    RMAN> alter database mount;
    
    database mounted
    released channel: ORA_DISK_1
    
    RMAN> recover database;
    
    Starting recover at 29-FEB-12 14:02:55
    Starting implicit crosscheck backup at 29-FEB-12 14:02:55
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=20 device type=DISK
    Crosschecked 96 objects
    Finished implicit crosscheck backup at 29-FEB-12 14:02:57
    
    Starting implicit crosscheck copy at 29-FEB-12 14:02:57
    using channel ORA_DISK_1
    Finished implicit crosscheck copy at 29-FEB-12 14:02:57
    
    searching for all files in the recovery area
    cataloging files...
    no files cataloged
    
    using channel ORA_DISK_1
    
    starting media recovery
    
    archived log for thread 1 with sequence 13 is already on disk as file /redo_archive/trgt/online/redo01.log
    archived log for thread 1 with sequence 14 is already on disk as file /redo_archive/trgt/online/redo02.log
    archived log for thread 1 with sequence 15 is already on disk as file /redo_archive/trgt/online/redo03.log
    archived log file name=/redo_archive/trgt/archive/1_10_776523284.dbf thread=1 sequence=10
    archived log file name=/redo_archive/trgt/archive/1_10_776523284.dbf thread=1 sequence=10
    archived log file name=/redo_archive/trgt/archive/1_11_776523284.dbf thread=1 sequence=11
    archived log file name=/redo_archive/trgt/archive/1_12_776523284.dbf thread=1 sequence=12
    archived log file name=/redo_archive/trgt/online/redo01.log thread=1 sequence=13
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of recover command at 02/29/2012 14:02:59
    ORA-01422: exact fetch returns more than requested number of rows
    RMAN-20505: create datafile during recovery
    RMAN-11003: failure during parse/execution of SQL statement: alter database recover logfile '/redo_archive/trgt/online/redo01.log'
    ORA-00283: recovery session canceled due to errors
    ORA-01244: unnamed datafile(s) added to control file by media recovery
    ORA-01110: data file 9: '/data3/trgt/CNT_TST03.dbf'
    
    RMAN> -- wnet to session 2 and renamed datafile from unammed
    -wnet to session 2 and renamed datafile for file unammed
    SQL> select name from v$datafile;
    
    NAME
    --------------------------------------------------------------------------------
    /data/trgt/system01.dbf
    /data/trgt/sysaux01.dbf
    /data/trgt/undotbs01.dbf
    /data3/trgt/move/users01.dbf
    /data3/trgt/user02.dbf
    /data3/trgt/users03.dbf
    /data3/trgt/cnt_tst01.dbf
    /oracle/app/product/11.2.0/dbhome_1/dbs/UNNAMED00008
    /oracle/app/product/11.2.0/dbhome_1/dbs/UNNAMED00009
    
    9 rows selected.
    
    SQL> alter database create datafile '/oracle/app/product/11.2.0/dbhome_1/dbs/UNNAMED00008' as '/data3/trgt/CNT_TST02.dbf';
    
    Database altered.
    
    SQL> alter database create datafile '/oracle/app/product/11.2.0/dbhome_1/dbs/UNNAMED00009' as '/data3/trgt/CNT_TST03.dbf';
    
    Database altered.
    
    SQL>  select name from v$datafile;
    
    NAME
    --------------------------------------------------------------------------------
    /data/trgt/system01.dbf
    /data/trgt/sysaux01.dbf
    /data/trgt/undotbs01.dbf
    /data3/trgt/move/users01.dbf
    /data3/trgt/user02.dbf
    /data3/trgt/users03.dbf
    /data3/trgt/cnt_tst01.dbf
    /data3/trgt/CNT_TST02.dbf
    /data3/trgt/CNT_TST03.dbf
    
    9 rows selected.
    After before was done, went back to session 1 and I tried recovered the DB
    RMAN> recover database;
    
    Starting recover at 29-FEB-12 14:06:16
    using channel ORA_DISK_1
    
    starting media recovery
    
    archived log for thread 1 with sequence 13 is already on disk as file /redo_archive/trgt/online/redo01.log
    archived log for thread 1 with sequence 14 is already on disk as file /redo_archive/trgt/online/redo02.log
    archived log for thread 1 with sequence 15 is already on disk as file /redo_archive/trgt/online/redo03.log
    archived log file name=/redo_archive/trgt/online/redo01.log thread=1 sequence=13
    archived log file name=/redo_archive/trgt/online/redo02.log thread=1 sequence=14
    archived log file name=/redo_archive/trgt/online/redo03.log thread=1 sequence=15
    media recovery complete, elapsed time: 00:00:00
    Finished recover at 29-FEB-12 14:06:17
    
    RMAN> alter database open resetlogs;
    
    database opened
    new incarnation of database registered in recovery catalog
    starting full resync of recovery catalog
    full resync complete
    starting full resync of recovery catalog
    full resync complete
    
    RMAN> exit
    
    
    Recovery Manager complete.
    [oracle@berry trgt]$
    [oracle@berry trgt]$
    [oracle@berry trgt]$ sq
    
    SQL*Plus: Release 11.2.0.1.0 Production on Wed Feb 29 14:07:18 2012
    
    Copyright (c) 1982, 2009, Oracle.  All rights reserved.
    
    
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    
    SQL> alter session set NLS_DATE_FORMAT="dd-mon-yy hh24:mi:ss:
      2
    SQL>
    SQL> alter session set NLS_DATE_FORMAT="dd-mon-yy hh24:mi:ss";
    
    Session altered.
    
    SQL> select count(*) from test.t2;
    select count(*) from test.t2
                              *
    ERROR at line 1:
    ORA-00376: file 8 cannot be read at this time
    ORA-01110: data file 8: '/data3/trgt/CNT_TST02.dbf'
    
    
    SQL> select max(c1) from test.t2;
    select max(c1) from test.t2
                             *
    ERROR at line 1:
    ORA-00376: file 8 cannot be read at this time
    ORA-01110: data file 8: '/data3/trgt/CNT_TST02.dbf'
    
    SQL> alter database datafile 8 online;
    alter database datafile 8 online
    *
    ERROR at line 1:
    ORA-01190: control file or data file 8 is from before the last RESETLOGS
    ORA-01110: data file 8: '/data3/trgt/CNT_TST02.dbf'
    
    {code}
    
    so what did i do wrong in my recovery that i could not get my data?? how can i avoid this?? and restore my DB?
    
    Edited by: user8363520 on Feb 29, 2012 12:24 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                

    user8363520 wrote:
    so can get us this or can't do?

    You seem to have:
    (a) old version of data through rman backup files
    (b) old version of the control file
    (c) Backed archived redo logs
    (d) recovery archived logs that have been recently generated
    (e) current online redo logs

    Therefore, you should be able to bring back the database in the State wherever it was when you made the abandonment.
    I don't do enough laps to be able to cite details on the commands to use (and I often find myself using the command line recovery after that file of rman restore, but the steps you need must be)

    Take a copy of security of the data current, archived and online redo log files.
    Restore the backup control file, data files, and archived recovery logs
    Recover the database by using up to cancel backup control file
    You have to do 'create datafile' bit as the collection hits the 'missing file' bit
    You will need to provide the names of the archived and log files online redo recovery reached their
    (although, presumably, you could leave copies of the logs stored in the default location)

    Concerning
    Jonathan Lewis
    http://jonathanlewis.WordPress.com
    Author: core Oracle

  • hot backup managed user problem

    Jin

    A few days ago, I took the managed user my database hot backup. And then, to check if the data file are in correct mode, I ran the query:

    SQL > select * sauvegardĪ˜ v$.

    FOLDER # STATUS CHANGES # TIMES
    ---------- ------------------ ---------- ---------
    1. NO ASSETS 6302304272 23 JANUARY 10
    2. NO ASSETS 6302305573 23 JANUARY 10
    3. NO ASSETS 6302304259 23 JANUARY 10
    4. NO ASSETS 6302305573 23 JANUARY 10
    5. NO ASSETS 6302305573 23 JANUARY 10
    6 0 NO ASSETS
    7 0 NO ASSETS



    And, I didn't know that all data files have completed end backup mode. But today, when I query v$ datafile_header to check the column fuzzy then I was shocked to see the result below:

    SQL > select fuzzy from v$ datafile_header;

    FUZ
    ---
    YES
    YES
    YES
    YES
    YES
    YES
    YES

    7 selected lines.

    I use oracle 9.2.0.8 on windows server 2003.


    Although the view of backup $ v shows the same 'NOT ACTIVE' because all data files.this make me very confused.


    Please give me some feedback...

    Kind regards

    V$ BACKUP and V$ DATAFILE_HEADER are two different views. Why confuse yourself? They are there to meet different requirements.

    V$ BACKUP is used to check if a data file is in backup mode.

    V$ DATAFILE_HEADER is used to check the header of a data file. Of course a datafile is BLURRED when the database is OPENED - independently of the question whether an online backup is running or has run earlier.

    Hemant K Collette
    http://hemantoracledba.blogspot.com

  • Oracle hot backup confusion

    Hello world
    This is a confusion on hot-backup Oracle.

    Suppose I have 3 online Redo Logs and I put a tablespace in backup Mode.
    So, whatever changes are made, Oracle will begin to generate redo for the entire block to avoid the fractured blocks.

    My Question is if, while doing this all my online Redo Logs files/members of Wat is full how do then Oracle manage to move forward and continue to save Transactions/changes to a Certain block in the Tablespace.


    1 > oracle runs a recovery from the archived Redo Logs once the Tablespace out of backup Mode.
    2 > or y at - it a fitness State/Re-sizing of the redo log file online space between other Segments.

    Thank you and best regards,
    Jean-Jacques Mukherjee.

    >
    I'm even not sure what #2 means! Anways.

    Suppose I have 3 online Redo Logs and I put a tablespace in backup Mode.

    No matter how many redo log groups you have and as I know it has no relationship to a tablespace in backup mode either.

    So, whatever changes are made, Oracle will begin to generate redo for the entire block to avoid the fractured blocks.

    Partially correct! The entire block is copied only for the first time . For subsequent changes, only agents of change go in the stamp newspaper, and from there, the redo log files. This is exactly what happens to a tablespace is not not in backup mode.

    My Question is if, while doing this all my online Redo Logs files/members of Wat is full how do then Oracle manage to move forward and continue to save Transactions/changes to a Certain block in the Tablespace.

    Does that mean exactly? If you complete the redo logs, switch journal will follow making the LGWR move from the current group of redo log to another, triggering the control point, which would make the DBWR write buffers in the data file. I don't know what is confusing?

    Edit: I apologize, I read this point a little too fast! If all the log files will be filled, database could be suspended. There will be transactions more because there is no place to write their vectors of change anywhere. Sorry, I realized in the first time you were talking about switching to the standard newspaper.

    1 > oracle runs a recovery of archived newspapers again once the data file is underwritten in backup Mode.

    What recovery? Before files go in the backup, there is a 'global' checkpoint which is executed for them, pushing them all buffers in the cache for them and then once the point control freezed for them, still let all read/write operations. Once they come on the backup mode, when the next time a checkpoint is made, then their number is synchronized with the rest of the database. Where the recovery comes into the picture here?

    2 > or y at - it a fitness State/Re-sizing of the redo log file online space between other Segments.

    As I said before, I didn't at all mean that point yet?

    HTH
    Aman...

    Published by: Edit added Aman... on October 24, 2009 21:19

  • The hot backup process

    Hello

    I have a Dev on Oracle 10 g (10.2.0.3 on Solaris 8) db, for which I want to set up a simple backup process hot. My question is: for simplicity, instead of putting each tablespace in backup mode and to take it out of backup mode, can I put the entire db in backup mode and copy the data files and control and take the Pb of backup mode:

    -J' my intention to do so hours offline when activities are lower and db is small and there is enough space to make it so again is generated (compared to each tablespace in backup mode) that this is acceptable. Thus, the following process is valid:

    (1) connecting to the db as sys
    (2) alter database begin backup
    (3) copy all of the files and control the db for the backup
    (4) change the backup of the end
    - or after it is necessary to issue the - modify the statement of system switch logfile also? -If so, what is the purpose of this statement?

    Also another question is: I don't have enough space on the db server hosting backups so after you put the db in backup mode, I transfer the file in Microsoft windows server for solaris. -Is possible with rman?
    The reason why I go to managed user backup, of rman is that we do not store the backup on the db Server nor we have any tape, but we have a windows machine that can be used to store backups. so in this case, is it possible that rman can be used?

    Thank you very much
    Cedric

    When you use RMAN, you don't have to put a tablespace (or database) in BACKUP Mode.

    With RMAN, you can create of BACKUPSETs, in this case, backups can be smaller than the actual database files as RMAN does not save the blocks that have never been used (that is to say, the blocks above the last measure in a data file). In addition, you can create AS COMPRESS in order to introduce more compression.
    Alternatively, you can creat backup as Copy, in which case backups are the same size as the data files that you might have with scripted backups (UserManaged).

    You MUST run your database in ArchiveLog mode.
    You MUST save each ArchiveLog.
    You must save your controlfiles as backup controlfile separate. However, even if you do not configure CONTROLFILE AUTOBACKUP ON, whenever you back up the SYSTEM Tablespace (that I advice every day), the controlfile is going to get backed up in the same backup set. For added convenience, I prefer controlfiles backup as separate backups so that they save files are easily identifiable.

  • Newbie sorry data-load question and datafile / viral measure

    Hi guys

    Sorry disturbing you - but I did a lot of reading and am still confused.

    I was asked to create a new tablespace:

    create tablespace xyz datafile 'oradata/corpdata/xyz.dbf' size 2048M extent management local size unique 1023M;

    alter tablespace xyz add datafile ' / oradata/corpdata/xyz.dbf' size 2048M;

    Despite being worried not given information about the data to load or why the tablespace must be sized that way - I was told to just 'do it '.

    Someone tried to load data - and there was a message in the alerts log.

    ORA-1652: unable to extend temp by 65472 segment in tablespace xyz

    We do not use autoextend on data files even if the person loading the data would be so (they are new on the environment).

    The database is on a cold backup nightly routine - we are in a rock anvil - we have no space on the server - to make RMAN and only 10 G left on the Strip for (Veritas) backup routine and thus control space with no autoextend management.

    As far as I know of the above error message is that the storage space is not large enough to hold the load data - but I was told by the person who imports the data they have it correctly dimensioned and it something I did when the database create order (although I have cut and pasted from their instructions - and I adapted to our environment - Windows 2003 SP2 but 32 bits).

    The person called to say I had messed up their data loading and was about to make me their manager for failing to do my job - and they did and my line manager said that I failed to correctly create the tablespace.

    When this person was asked to create the tablespace I asked why they thought that extensions should be 1023M and said it was a large data load that must be inserted to a certain extent.

    That sounds good... but I'm confused.

    1023M is very much - this means that you have only four extents in the tablespace until it reaches capacity.

    It is a load - is GIS data - I have not participated in the previous data loads GIS - other than monitor and change of tablespaces to support - and previous people have size it right - and I've never had no return. Guess I'm a bit lazy - just did as they asked.

    However, they never used 128K as a size measure never 1023M.

    Can I ask is 1023 M normal for large data loads - or I'm just the question - it seems excessive unless you really just a table and an index of 1023M?

    Thanks for any idea or other research.

    Assuming a block size of 8 KB, 65472 would be 511 MB. However, as it is a GIS database, my guess is that the database block size itself has been set to 16K, then 65472 is 1023MB.

    What load data is done? Oracle Export dump? Which includes a CREATE INDEX statement?
    Export-Import is a CREATE TABLE and INSERT so that you would get an ORA-1652 on it. So you get ORA-1652 if the array is created.
    However, you will get an ORA-1652 on an INDEX to CREATE the target segment (ie the Index) for this operation is initially created as a 'temporary' segment until the Index build is complete when it switches to be a 'temporary' to be a segment of "index".

    Also, if parallelism is used, each parallel operation would attempt to assign degrees of 1023 MB. Therefore, even if the final index target should have been only, say 512 MB, a CREATE INDEX with a DEGREE of 4 would begin with 4 extensions of 1023 MB each and would not decrease to less than that!

    A measure of 1023 MB size is, in my opinion, very bad. My guess is that they came up with an estimate of the size of the table and thought that the table should be inserted in 1 measure and, therefore, specified 1023 MB in the script that is provided to you. And it is wrong.

    Same Oracle AUTOALLOCATE goes only up to 64 MB extended when a Segment reached the mark of 1 GB.

Maybe you are looking for