Turn datafile offline

I am using oracle 8i and turned a data file offline by :
ALTER DATABASE DATAFILE '/ua01/oradata/hdb1/tmp01.dbf' OFFLINE DROP;
However, the status in dba_data_files is still AVAILABLE, is it correct?
Regards,
Jimmy

I am using oracle 8i and turned a data file offline
However, the status in dba_data_files is still AVAILABLE, is it correct?Yes this behaviour is correct and this link will give you an explanation.
http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:515222144417

Similar Messages

  • Taking the datafile offline when the database is in NOARCHIVELOG mode

    My question is when the database is in No Archive log mode i'm not able to take the datafile offline.
    When i tried in my computer i have noticed fallowing.
    case1:
    SYS>alter database datafile 5 offline;
    ERROR at line1;
    ORA-01145:offline immediate disallowed unless media recovery enabled.
    case 2:
    SYS>alter database datafile 5 offline immediate;
    ERROR at line 1;
    ORA-00933:SQL command not properly ended
    case3:
    I have tried the command alter database datafile 6 offline drop; (in NOARCHIVELOG mode) and it is showing the same effect as alter database datafile 6 offline; ( in ARCHIVELOG mode).
    *In the NOARCHIVELOG mode are we really dropping the datafile to take the datafile offline? Will you please tell me the effect of keyword drop.

    JohnWatson wrote:
    You've marked your question answered - was that a mistake?
    The answer is that you cannot directly take a datafile offline in noarchivelog mode. You must take the tablespace offline:
    Hmm, are you certain about that? Perhaps I'm missing something.
    SQL> select file_id, file_name, online_status, status from dba_data_files where tablespace_name = 'USERS';
       FILE_ID FILE_NAME                                          ONLINE_ STATUS
             4 /u01/app/oracle/oradata/TEST/users01.dbf           ONLINE  AVAILABLE
    SQL> select log_mode from v$database;
    LOG_MODE
    NOARCHIVELOG
    SQL> alter database datafile 4 offline drop;
    Database altered.
    SQL> select file_id, file_name, online_status, status from dba_data_files where tablespace_name = 'USERS';
       FILE_ID FILE_NAME                                          ONLINE_ STATUS
             4 /u01/app/oracle/oradata/TEST/users01.dbf           RECOVER AVAILABLE
    SQL>  ALTER SYSTEM FLUSH BUFFER_CACHE;  <-- may not have been necessary
    System altered.
    SQL> select count(*) from scott.emp;
    select count(*) from scott.emp
    ERROR at line 1:
    ORA-00376: file 4 cannot be read at this time
    ORA-01110: data file 4: '/u01/app/oracle/oradata/TEST/users01.dbf'
    SQL> recover datafile 4;
    Media recovery complete.
    SQL> select file_id, file_name, online_status, status from dba_data_files where tablespace_name = 'USERS';
       FILE_ID FILE_NAME                                          ONLINE_ STATUS
             4 /u01/app/oracle/oradata/TEST/users01.dbf           OFFLINE AVAILABLE
    SQL> alter database datafile 4 online;
    Database altered.
    SQL> select file_id, file_name, online_status, status from dba_data_files where tablespace_name = 'USERS';
       FILE_ID FILE_NAME                                          ONLINE_ STATUS
             4 /u01/app/oracle/oradata/TEST/users01.dbf           ONLINE  AVAILABLE
    SQL> select count(*) from scott.emp;
      COUNT(*)
            14
    Also, please see the following link from the manual which discusses altering data file availability in noarchivelog mode.
    Altering Datafile Availability

  • Automatic datafile offline due to write error

    Hi,
    Our SAP system are down. In the alert.log file, i found that one of the files are being locked by third party backup software.
    I'm new to both oracle and basis, pls advise the steps to recover the database. Thank you.
    The error in the alert log file:
    Errors in file f:\oracle\p02\saptrace\background\p02_lgwr_3896.trc:
    ORA-00345: redo log write error block 8404 count 2
    ORA-00312: online log 3 thread 1: 'D:\ORACLE\P02\ORIGLOGA\LOG_G13M1.DBF'
    ORA-27072: File I/O error
    OSD-04008: WriteFile() failure, unable to write to file
    O/S-Error: (OS 33) The process cannot access the file because another process has locked a portion of the file.
    Sat Oct 25 00:23:12 2008
    Errors in file f:\oracle\p02\saptrace\background\p02_lgwr_3896.trc:
    ORA-00343: too many errors, log member closed
    ORA-00346: log member marked as STALE
    ORA-00312: online log 3 thread 1: 'D:\ORACLE\P02\ORIGLOGA\LOG_G13M1.DBF'
    Sat Oct 25 00:26:04 2008
    Incremental checkpoint up to RBA [0x1c1b.2079.0], current log tail at RBA [0x1c1b.20dc.0]
    Sat Oct 25 00:35:18 2008
    KCF: write/open error block=0x3f7c6 online=1
         file=5 G:\ORACLE\P02\SAPDATA1\SR3_2\SR3.DATA2
         error=27072 txt: 'OSD-04008: WriteFile() failure, unable to write to file
    O/S-Error: (OS 33) The process cannot access the file because another process has locked a portion of the file.'
    Automatic datafile offline due to write error on
    file 5: G:\ORACLE\P02\SAPDATA1\SR3_2\SR3.DATA2
    Sat Oct 25 00:35:19 2008
    KCF: write/open error block=0x3f7c4 online=1
         file=5 G:\ORACLE\P02\SAPDATA1\SR3_2\SR3.DATA2
         error=27070 txt: 'OSD-04016: Error queuing an asynchronous I/O request.
    O/S-Error: (OS 33) The process cannot access the file because another process has locked a portion of the file.'
    Automatic datafile offline due to write error on
    file 5: G:\ORACLE\P02\SAPDATA1\SR3_2\SR3.DATA2
    Sat Oct 25 00:36:00 2008
    KCF: write/open error block=0x37f74 online=1
         file=7 G:\ORACLE\P02\SAPDATA1\SR3_4\SR3.DATA4
         error=27072 txt: 'OSD-04008: WriteFile() failure, unable to write to file
    O/S-Error: (OS 33) The process cannot access the file because another process has locked a portion of the file.'
    Automatic datafile offline due to write error on
    file 7: G:\ORACLE\P02\SAPDATA1\SR3_4\SR3.DATA4
    Sat Oct 25 00:45:49 2008
    Errors in file f:\oracle\p02\saptrace\usertrace\p02_ora_3876.trc:
    ORA-00600: internal error code, arguments: [kdtdelrow-2], [2], [2], [], [], [], [], []
    ORA-00376: file 5 cannot be read at this time
    ORA-01110: data file 5: 'G:\ORACLE\P02\SAPDATA1\SR3_2\SR3.DATA2'

    Hi
    As alway use this information for research purposes only.
    I presume that Oracle and SAP application servers are down.
    Now would be a good time to make a backup image of your crippled system.
    This way you can always get back to this state if needed.
    So do an offline backup if possible.
    It looks like a log file is damaged or deleted. You may find that you have a
    mirror image of it so this might not be the end of the world.
    If you have oracle up to the mount point e.g.
    startup mount
    then you should be able to acces the v$logfile
    select  GROUP#,STATUS,MEMBER from v$logfile;
    This will show you whether the have a mirror setup for the log file you need.
    Make sure all the files outlined in this output exist.
    e.g. do a DIR in the parant directory.
    Post all the output of v$logfile and whether all the files exist.
    regards
    Stephen

  • No Online backups due to datafiles offline than I canu0092t recover. How...?

    Hi gurus!!!
    I got into a problem with some datafiles.
    We have MySAP in a BD oracle 9.2.0.6
    I used Oracle Entreprise Manager Console to generate two datafiles in the tablespace PSAPPRDUSR,
    but I generated them in another tablesapce (PSAPPRD) with a name of file,
    size and location very different from those that there uses the tablespace PSAPPRD.
    <b>So... I put them offline later to erase them later!!!</b>
    <b>The datafiles contains no data.</b>
    <b>Later, in the night backup:</b>
       BR0334W Status of database file /oracle/PRD/sapdata4/prdusr_2/prdusr.data2 is RECOVER 
       BR0334W Status of database file /oracle/PRD/sapdata4/prdusr_2/prdusr.data2a is RECOVER
       BR0301E SQL error -1128 at location BrTspAlter-3                    
       ORA-01128: cannot start online backup - file 31 is offline          
       ORA-01110: data file 31: '/oracle/PRD/sapdata4/prdusr_2/prdusr.data2'
       BR0280I BRBACKUP time stamp: 2007-04-20 03.01.21                    
       BR0316E 'Alter tablespace PSAPPRD begin backup' failed              
       BR0056I End of database backup: bdvbtndh.ant 2007-04-20 03.01.21    
    <b>
    And now... I neither can erase them nor can put online again.</b>
    <b>To erase them I used:</b>
    SQL> ALTER DATABASE DATAFILE '/oracle/PRD/sapdata4/prdusr_2/prdusr.data2' OFFLINE DROP;
    Database altered.
    SQL> commit;
    But they continue there, do not resign.
    <b>To put them online:</b>
    SQL> alter database recover datafile '/oracle/PRD/sapdata4/prdusr_2/prdusr.data2';
    alter database recover datafile '/oracle/PRD/sapdata4/prdusr_2/prdusr.data2'
    ERROR at line 1:
    ORA-00279: change 31203204 generated at 04/19/2007 19:30:11 needed for thread 1
    ORA-00289: suggestion : /oracle/PRD/oraarch/PRDarch1_2574.dbf
    ORA-00280: change 31203204 for thread 1 is in sequence #2574
    SQL>
    <b>But we have continued working and I don't want to lose any data.</b>
    HEEEELP!!!!
    What I can do to recover the datafiles and to continue with my daily Online backups?
    The BD is in production and I do not have long time to fix it, only a few hours on Saturdays night.

    Hi,
    alter database datafile offline drop;
    This command is not meant to drop a datafile. It is meant to offline the datafile with the intention of dropping the tablespace.
    For a tablespace comprising multiple datafiles you can only drop a datafile by dropping the entire tablespace, this will work even you have one datafile.
    If you have 10gr2, it's finally possible to drop a datafile as long as
    it's not the only datafile within the tablespace, and
    the tablespace is only and in read-write status.
    So since you are on 9i your situation in summary:
    If you have more than one datafile in the tablespace and you wish to keep the objects that reside in the other datafile(s) which are part of this tablespace, then you must export all the objects inside the tablespace.
    1. Gather information on the current datafiles within the tablespace by running some query to remember the t/s, segment, and datafile info.
    2. Export all the objects that you wish to keep.
    3. Once the export is done, issue the DROP TABLESPACE <tablespace name> INCLUDING CONTENTS.
    4. Delete the datafiles belonging to this tablespace using the operating system.
    5. Recreate the tablespace with the datafile(s) desired, then import the objects into that tablespace.
    Hope this helps and good luck,
    George

  • Taking a datafile offline

    Hello -
    I am running an Oracle 8.1.7.4 database in archivelog mode. Can I take a datafile offline, rename the datafile, then bring the datafile back online?
    For example,
    1. alter database datafile 'string' offline;
    2. rename the datafile at the os level
    3. alter database rename file 'string' to 'newstring';
    alter database datafile 'newstring' online;
    While the datafile is offline, does this cause errors if an attempt is made to access the datafile?

    Of course, as already posted, data in the offline datafile are not available, so you cannot access them. In my case, those data were previous years accounting data, and people asked for mounting removable disks when they needed them.

  • Datafile offline drop

    Dear all,
    In my DB, one datafile got corrupted. DB running in noarchive log mode. I took a complete export of the DB. now I took the datafile offline by
    alter database datafile 7 offline drop;
    now I can able to open the database, now what should I do ?.. still in dba_data_files, this corrupted file is shown..shall I drop this file alone ?.. how ?..I have already 2 other datafiles in the same tablespace ..
    Kai

    In my DB, one datafile got corruptedHOW??
    alter database datafile 7 offline drop; It seems you are using version lower than 10g.This will offline the datafile with the intention of dropping the tablespace.Oracle no longer attempts to access it, but it is still considered part of that tablespace.The datafile is marked offline in the controlfile.So, you will see the datafile in the dba_data_files.The data in the offline datafile won't be available to the users.
    But from 10g and higher version, you can finally drop the datafile
    alter tablespace tbs_name drop datafile 'datafile_name';
    10g link [http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/dfiles.htm#sthref1396]
    now I can able to open the database, now what should I do ?What actually you want to do. what do you want to do.
    HTH
    Anand

  • Taking rollback segment and datafile offline caused application error

    One of the DBA's added a large rollback segment which caused the rman backup to abort. The rollback segment was taking offline and it's datafile was taken offline, all went normally no errors. An Application started gettting errors the database and application were taking down and up, no errors on either but the problem was still there. The rbs datafile and RBS were placed back online and the application worked properly. It looks as if Oracle let us take the RBS and datafile offline with active segments in the RBS is this possible?? If so it means you can pull the rug out from under Oracle and it doesn't even complain

    Pls check any transactions written in application level,
    explicitly assigned to the RBs which was taken offline.

  • TS4006 Last known fix for Find my iPad? How is this not an included option for devices that are currently turned off.  Absolute no brainer.  Thief steals the iPad and turns it offline, or user loses it while it has low battery, lost forever.  Brilliant.

    Last known fix for Find my iPad? How is this not an included option for devices that are currently turned off.  Absolute no brainer.  Thief steals the iPad and turns it offline, or user loses it while it has low battery, lost forever.  Brilliant.

    If the iPad was running iOS 7, the thief/finder will not ever be able to use it.
    iCloud: Find My iPhone Activation Lock in iOS 7
    http://support.apple.com/kb/HT5818
    Apple (and no one else) can not assist (with serial number or iCloud) in finding a lost or stolen iPad.
    Report to police along with serial number. Change all your passwords.
    These links may be helpful.
    How to Track and Report Stolen iPad
    http://www.ipadastic.com/tutorials/how-to-track-and-report-stolen-ipad
    Reporting a lost or stolen Apple product
    http://support.apple.com/kb/ht2526
    What to do if your iOS device is lost or stolen
    http://support.apple.com/kb/HT5668
    iCloud: Locate your device on a map
    http://support.apple.com/kb/PH2698
    iCloud: Lost Mode - Lock and Trace
    http://support.apple.com/kb/PH2700
    iCloud: Remotely Erase your device
    http://support.apple.com/kb/PH2701
    Report Stolen iPad Tips and iPad Theft Prevention
    http://www.stolen-property.com/report-stolen-ipad.php
    General steps to follow for a Stolen iPad
    http://stolen-ipad.com/
    How to recover a lost or stolen iPad
    http://ipadhelp.com/ipad-help/how-to-recover-a-lost-or-stolen-ipad/
    How to Find a Stolen iPad
    http://www.ehow.com/how_7586429_stolen-ipad.html
    What NOT to do if your iPhone or iPad is lost or stolen
    http://www.tomahaiku.com/what-not-to-do-if-your-iphone-or-ipad-lost-or-stolen/
    Apple Product Lost or Stolen
    http://sites.google.com/site/appleclubfhs/support/advice-and-articles/lost-or-st Len
    Oops! iForgot My New iPad On the Plane; Now What?
    http://online.wsj.com/article/SB10001424052702303459004577362194012634000.html
    If you don't know your lost/stolen iPad's serial number, use the instructions below. The S/N is also on the iPad's box.
    How to Find Your iPad Serial Number
    http://www.ipadastic.com/tutorials/how-to-find-your-ipad-serial-number
    iOS: How to find the serial number, IMEI, MEID, CDN, and ICCID number
    http://support.apple.com/kb/HT4061
     Cheers, Tom

  • Deleted archive files during the datafile offline period

    Dear Gurus
    I want to report a mishap that happened in one of our system.
    I made one of the data files x01.dbf offline(the only datafile for that tablespace say X )
    Now unfortunately i deleted the archives during the period the datafile was offline ..
    Now it is not letting me do any operation like any ddl operation ..
    How can I restore the database back to normal .
    Thanks in advance
    abhi

    Hi again,
    Dear GuruOh la, I'm not a guru, just an old oracle newwbie!
    I did not understand what was that 7 error game :)Lesson learned: do not try to translate obscure French stuff :-)
    About your problem, if this does not work, you have only one possibility: drop it. If the drop fails you'll have to bounce the database in order to do that.
    If you have to "recover" from the tablespace loss, you'll have to do some TSPITR (Tablespace Point In Time Recovery).
    HTH,
    Yoann.

  • Datafile offline

    Dear all
    I have just completed a cloning.One of my datafile is offline.
    In the control file it is pointing to a different path with a ficticious filename like
    /nd01/oradev/devdb/9.2.0/dbs/MISSING00098'
    The file I want is under location another location.I tried to generate a trace control file and run it on nomout mode,but still no luck.
    Can somebody help me.

    I do not have datafile name MISSING.
    It generated the name.I tried to generate a script
    from alter database backup controlfile to trace.But
    still NO LUCK.
    Regardsthis's from your original post,
    I have just completed a cloning.One of my datafile is offline.
    In the control file it is pointing to a different path with a ficticious filename like
    >>/nd01/oradev/devdb/9.2.0/dbs/MISSING00098'
    Compare your output of
    select name from v$datafile;from source and cloned database

  • Datafile Offline dropped.

    I have added a datafile to a tablespace and did the offline drop immediately since it was not adhering to the naming convention.
    Is their a way I can get rid off that file since the controlfile still has that entry.
    I can't drop and recreate the tablespace bec. of the size constraint (250GB).
    DB version: 9.2.0.7
    Any help would be really appreciable.

    Hi
    Have a look at Note:111316.1.
    Hope this Helps
    Regards

  • Datafile offline in reade only mode

    i read the oracle9i reference and it show me the message
    'Read-only mode does not restrict database recovery or operations that change the
    database’s state without generating redo data. For example, in read-only mode:
    Datafiles can be taken offline and online
    Offline datafiles and tablespaces can be recovered
    The control file remains available for updates about the state of the database'
    first one the message show me is 'datafiles can be taken offline and online' , i think this tell me i can change the datafiles's state online to offline, so when i use
    alter database datafile test.ora offline is a error ora-01145 in the noarchivelog mode
    but it is successful in the archivelog mode
    so could anyone tell the distinct of two mode the database and tablespace offline

    The docs are at http://tahiti.oracle.com.
    No doubt while reading the docs you will find other valuable information that someone writing you a short paragraph would omit.

  • Problem To Recover Database (Cannot Take Datafile Offline)

    Hi
    I have a Oracle10g Database in Linux ...
    By Mistake I Delete one Datafile From. Now I can't Start My Database..
    I am Tring to get Offline The Deleted Data File..But can't do it..
    To Detail of my Work is geven bellow....
    SQL> startup mount
    ORACLE instance started.
    Total System Global Area 281018368 bytes
    Fixed Size 1218968 bytes
    Variable Size 83887720 bytes
    Database Buffers 192937984 bytes
    Redo Buffers 2973696 bytes
    Database mounted.
    SQL> alter database open
    2 ;
    alter database open
    ERROR at line 1:
    ORA-01122: database file 6 failed verification check
    ORA-01110: data file 6: '/u01/app/oracle/db_2/dbs/DNS_DATA_1'
    ORA-01251: Unknown File Header Version read for file number 6
    SQL> alter database datafile '/u01/app/oracle/db_2/dbs/DNS_DATA_1' offline immediate;
    alter database datafile '/u01/app/oracle/db_2/dbs/DNS_DATA_1' offline immediate
    ERROR at line 1:
    ORA-00933: SQL command not properly ended
    SQL> alter database datafile '/u01/app/oracle/db_2/dbs/DNS_DATA_1' offline;
    alter database datafile '/u01/app/oracle/db_2/dbs/DNS_DATA_1' offline
    ERROR at line 1:
    ORA-01145: offline immediate disallowed unless media recovery enabled
    SQL>
    Any One pls Help me...

    Seems that your DB is running in NOARCHIVELOG mode : try using "offline drop" :
    SQL> alter database datafile '/u01/app/oracle/db_2/dbs/DNS_DATA_1' offline drop;

  • Taking datafile offline and moving it.

    How i can move my datafile? what are steps ?

    SYS@db102 SQL> select * from dba_data_files  where tablespace_name='TEST';
    FILE_NAME
       FILE_ID TABLESPACE_NAME                     BYTES     BLOCKS STATUS    RELATIVE_FNO AUT
      MAXBYTES  MAXBLOCKS INCREMENT_BY USER_BYTES USER_BLOCKS ONLINE_
    /home/ora102/oradata/db102/test01.dbf
             5 TEST                             20971520       2560 AVAILABLE            5 NO
             0          0            0   20905984        2552 ONLINE
    SYS@db102 SQL> alter database datafile 5 offline;
    Database altered.
    SYS@db102 SQL> exit
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    [ora102 ~ db102]$ mv /home/ora102/oradata/db102/test01.dbf /tmp/test01.dbf
    [ora102 ~ db102]$ sqlplus / as sysdba
    SQL*Plus: Release 10.2.0.1.0 - Production on Tue Sep 26 20:46:25 2006
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    SYS@db102 SQL> alter database rename file '/home/ora102/oradata/db102/test01.dbf' to '/tmp/test01.dbf';
    Database altered.
    SYS@db102 SQL> recover datafile 5;
    Media recovery complete.
    SYS@db102 SQL> alter database datafile 5 online;
    Database altered.
    SYS@db102 SQL> select * from dba_data_files where tablespace_name='TEST';
    FILE_NAME
       FILE_ID TABLESPACE_NAME                     BYTES     BLOCKS STATUS    RELATIVE_FNO AUT
      MAXBYTES  MAXBLOCKS INCREMENT_BY USER_BYTES USER_BLOCKS ONLINE_
    /tmp/test01.dbf
             5 TEST                             20971520       2560 AVAILABLE            5 NO
             0          0            0   20905984        2552 ONLINE
    SYS@db102 SQL>                                                                 

  • Datafile offline后 无法online

    数据文件1个月前前被offline 后,忘了online
    最近才发现这个问题,rman 的的备份策略是保存一周,.现在数据文件是recover 状态
    SQL> select status from v$datafile;
    STATUS
    SYSTEM
    ONLINE
    ONLINE
    ONLINE
    ONLINE
    RECOVER
    进行了如下操作
    [oracle@localhost ~]$ rman target /
    Recovery Manager: Release 10.2.0.1.0 - Production on Sun Oct 14 15:21:39 2012
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    connected to target database: ORCL (DBID=1282456281)
    RMAN> restore datafile 6;
    Starting restore at 14-OCT-12
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=158 devtype=DISK
    channel ORA_DISK_1: starting datafile backupset restore
    channel ORA_DISK_1: specifying datafile(s) to restore from backup set
    restoring datafile 00006 to /u01/app/oracle/oradata/orcl/test.dbf
    channel ORA_DISK_1: reading from backup piece /u01/app/oracle/flash_recovery_area/ORCL/backupset/2012_10_14/o1_mf_nnndf_TAG20121014T113901_87ndypbn_.bkp
    channel ORA_DISK_1: restored backup piece 1
    piece handle=/u01/app/oracle/flash_recovery_area/ORCL/backupset/2012_10_14/o1_mf_nnndf_TAG20121014T113901_87ndypbn_.bkp tag=TAG20121014T113901
    channel ORA_DISK_1: restore complete, elapsed time: 00:00:15
    Finished restore at 14-OCT-12
    RMAN> recover datafile 6;
    Starting recover at 14-OCT-12
    using channel ORA_DISK_1
    starting media recovery
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of recover command at 10/14/2012 15:22:33
    RMAN-06053: unable to perform media recovery because of missing log
    RMAN-06025: no backup of log thread 1 seq 97 lowscn 10552775 found to restore
    RMAN-06025: no backup of log thread 1 seq 96 lowscn 10552545 found to restore
    RMAN-06025: no backup of log thread 1 seq 95 lowscn 10550471 found to restore
    RMAN> exit
    Recovery Manager complete.
    --一周前的全备和增量备份,归档日志已经被删除
    [oracle@localhost ~]$
    [oracle@localhost ~]$
    [oracle@localhost ~]$
    [oracle@localhost ~]$ sqlplus / as sysdba
    SQL*Plus: Release 10.2.0.1.0 - Production on Sun Oct 14 15:22:51 2012
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    SQL> shutdown immediate
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> startup mount
    ORACLE instance started.
    Total System Global Area 1241513984 bytes
    Fixed Size 1219136 bytes
    Variable Size 335545792 bytes
    Database Buffers 889192448 bytes
    Redo Buffers 15556608 bytes
    Database mounted.
    SQL> alter database open;
    Database altered.
    数据库能正常启动
    SQL> select status from v$datafile;
    STATUS
    SYSTEM
    ONLINE
    ONLINE
    ONLINE
    ONLINE
    RECOVER
    6 rows selected.
    状态还是recover 状态
    SQL> alter database datafile 6 online;
    alter database datafile 6 online
    ERROR at line 1:
    ORA-01113: file 6 needs media recovery
    ORA-01110: data file 6: '/u01/app/oracle/oradata/orcl/test.dbf'
    如何使该数据文件online ?
    以上环境是我的模拟的 有一个生产库和该情况基本一样

    谢谢 部分归档日志的备份已经被删除(因为备份策略 不可能保存所有的归档日志)
    只有选择第二种了.
    数据文件意外offline 或变成recover状态,由于对系统没有影响(如我遇到SYSAUX表空间),一直没有发现,能到发现了,已经是很长时间了,归档日志已经不全了(备份策略没有保存那么长时间)
    这类问题有什么好的办法可以避免吗?

Maybe you are looking for

  • Syncing iPhone changes the dates of my events in iCal

    Hiya - I have a new iPhone 3g... When I sync it through iTunes it sets the date on iMac as the following day - ie an event that inputted on the phone on Mon 13th shows on the computer as being on Tues 14th... Both seem set to the same time and date -

  • Commission Agent  Settings

    Hi, As for my Business i need to configure the Commission Agent (Broker) its a textile Industry. In this there is not standard for each customer can have more 2 and also maximum percentage is 2% (Total Percentage) this percentage will be divided into

  • Problem with Print Preview  Urgent!

    Hello BW Experts, 1.I am trying to use the Print functionality for web printing.In the print preveiew i see all the text in black and white.It is completely different from the page that is displayed in the browser. --I tried using the same print styl

  • Unable to Restore Disk Image of TM Backups

    I am trying to Restore disk images of TM backups to a newly formatted (OSx extended - journaled) 500MB firewire drive. I created 2 partitions, One for each TM image of the backups for my two Macbooks. When I follow the prompts to restore in DU, the p

  • I am trying to set up sync on my desktop, so I can sync my ipad. When I enter my email address, it says unknown error. I've tried several email addresses.

    When trying to set up a sync account, the first thing I have to do is enter my email address. When I begin typing that, I get an "invalid email address" just below it. I understand this is because I haven't finished typing it. Once I finish typing th