I have lost my database on the server because the computer has been formatted on drive C. But the oracle folder was located on Drive E, like oradata, etc. Can I restore oracle database like before?
Asked
Active
Viewed 4,306 times
1 Answers
1
Well, first you need to install the oracle server with the version which was there before formatting.
Follow these steps:
- Install the same Oracle database version with the starter database.
- Copy all control files, datafiles to oradata directory
- Copy init.ora filr to ADMIN folder
- Revise the init.ora file for the changed control file, archive and dump locations. (keep instance, SID, and global db name the same)
- Create the instance by running oradim with the pfile(init.ora) location
- Connect to DB using internal and mount it.
Check existing data and logfile locations by typing:
SELECT name FROM V$DATAFILE; SELECT member FROM V$LOGFILE;
Now change the file locations that come up above by using:
ALTER DATABASE RENAME FILE <old file loc list> to <new file loc list>;
- After renaming them open the database by alter database open.
And you should be set.