Simpler Navigation for Servers and Operating Systems
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
Showing results for 
Search instead for 
Did you mean: 

Erase an Oracle 8.1.7 instance

Chartier Jerome
Frequent Advisor

Erase an Oracle 8.1.7 instance


What is the procedure to erase an Oracle 8.1.7 instance (drop tables, truncate,.....????).

Thanks in advance for your help


T G Manikandan
Honored Contributor

Re: Erase an Oracle 8.1.7 instance

If you want to delete/drop/remove a database
do the steps below

check your ORACLE_SID and ORACLE_HOME.
Make sure that you are pointing the right ORACLE_SID

01. $svrmgrl
02. startup the database if it's not already started. The database must at least mounted.
svrmgrl>startup mount
03. spool /databasefiles.lst
svrmgrl>spool databasefiles.lst
04. select name from v$datafile; (This will get all the datafiles; alternatively, you can select file_name from dba_data_files)
svrmgrl>select name from v$datafile;
05. select member from v$logfile;
svrmgrl>select * from v$logfile;
06. select name from v$controlfile;
svrmgrl>select * from v$controlfile;
07. archive log list (archive_log_dest is where the archived destination is)
svrmgrl>archive log list;
Go to the destination directory of archive_log_dest parameter and remove all the files.
08. locating ifile by issuing show parameter ifile (alternatively, check the content of init.ora)
09. spool off
svrmgrl>spool off
10. Delete in O/S level the files listed in databasefiles.lst
11. remove all the entries which refer to the deleted database in tnsnames.ora and listener.ora (located in $ORACLE_HOME/network/admin)
12. remove all database links referring to the deleted database.
13. check "/var/opt/oracle/oratab" to make sure there is no entry of the database deleted. If yes, remove it.

Andreas D. Skjervold
Honored Contributor

Re: Erase an Oracle 8.1.7 instance


would add:
13. /etc/oratab for HP-UX systems

14. remove $ORACLE_HOME/dbs/init.oralink and orapw if present.

Only by ignoring what everyone think is important, can you be aware of what everyone ignores!