Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: REALLY urgent : Beginner's dumb question (O7.3)

Re: REALLY urgent : Beginner's dumb question (O7.3)

From: Dave Wotton <Dave.Wotton_at_no-spam.it.camcnty.gov.uk>
Date: 22 Sep 1998 14:18:22 GMT
Message-ID: <6u8bje$igq$1@dns.camcnty.gov.uk>


>
> From: "Tarek Chouman" <tchouman_at_bigfoot.com>
> Date: Mon, 21 Sep 1998 19:06:46 +0200
>
>I created an additional datafile in my tablespace (2 datafiles).
>I then noticed that this file was created in the wrong place on my AIX.
>I removed it using "rm".
>My tablespace is offline.
>How can I delete the logical reference Oracle has on the datafile
>which doesn't exist anymore ?
>My tablespace cannot be shifted to online (everybody is shouting at me)
>because the datafile I removed doesn't exist and I cannot find any statement
>to remove the datafile from Oracle's internal tables.
>Please help :-O

Hi,

The other replies posted to this question are correct: you're into a recovery situation here. Winnie Liu explains clearly how to recover if you've got an export of the tablespace but (a) you probably haven't and (b) it's only useful to recover just that tablespace from an export providing that the data in it isn't dependent on other data in other tablespaces. If it is, all your data dependencies will be shot.

You might be better off restoring the files which make up the broken tablespace from a backup and performing a point-in-time recovery from the redo logs ( you should be able to see from the alert log exactly what time it was you deleted the file ).

To do a point-in-time recovery, you must have ALL the redo logs generated since the last full backup. If you've got archive logging switched on, you should have them. If not you might or might not be able to recover: look in the alert log to see how many log switches have occurred since the last backup. If there have been fewer than the number of online redo logs you've defined, then all the recovery data you need is still in the online redo logs and you can recover. If there have been more log switches than online redo logs, and you're not in archive log mode then some of the redo data has been overwritten and you've had it.

If you're not doing archive logging, stop your users using the database NOW. Your online redo logs might not yet have been overwritten, but they soon will be if the users keep using the system. To recover the database, restore just the files which make up the broken tablespace from the last backup and the control files, startup the database with mount option, RECOVER DATABASE UNTIL <time> USING BACKUP CONTROLFILE; You need the old control file, because your current one knows about the missing file.

I've never had to recover from this particular situation, so I can't guarantee it'll work. It might be a good idea to back up everything before attempting the recovery. If anything then goes wrong, at least you haven't made things worse.

Once you've got everything back. Perform another backup.

Good luck.

Dave.
--
Remove the no-spam bit from my email address to reply. Received on Tue Sep 22 1998 - 09:18:22 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US