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

Home -> Community -> Usenet -> c.d.o.tools -> Re: How to COMPLETELY uninstall 8.0.5 on NT 4.0?

Re: How to COMPLETELY uninstall 8.0.5 on NT 4.0?

From: Eric Givler <egivler_at_flash.net>
Date: Thu, 07 Sep 2000 20:09:23 GMT
Message-ID: <TBSt5.2105$yY.149015@news.flash.net>

  Bookmark Fixed font Go to End

Doc ID: Note:62004.1
Subject: Removing a Oracle Instance and Database from Windows NT Type: BULLETIN
Status: PUBLISHED
 Content Type: TEXT/PLAIN
Creation Date: 30-JUN-1998
Last Revision Date: 26-MAR-2000
Language: USAENG

PURPOSE



This note explains how you can remove an entire instance and database and all related links from a Microsoft Windows NT box.

SCOPE & APPLICATION



The intended audience for this article is Oracle DBAs who have a moderate knowledge of Oracle7 or Oracle8 Server. This bulletin makes the following assumptions:

Related Notes



Note:61621.1 RECREATING ORACLE7 AND ORACLE8 SERVICES AND INSTANCES

             FROM COMMAND LINE Removing a Oracle Instance and Database from Windows NT


This bulletin makes the following assumptions:

      o The SID of the instance to be removed is TEST.
      o The Oracle Home is C:\Orant.
      o Text surrounded by brackets, such as <filename>, is to be
 interpreted as a variable that needs to be replaced -  without brackets - with an appropriate value of the type  specified.
      o Oracle 7.3 ==> svrmgr23 , oradim73, rdbms73
        Oracle 8.0 ==> svrmgr30 , oradim80, rdbms80
        Oracle 8.1 ==> svrmgrl  , oradim  , rdbms
        In general svrmgrxx, oradimxx
      o To which instance is one connecting
       1. LOCAL variable
       2. ORACLE_SID
       Both can be defined at
       a) registry
           * LOCAL
               if the database has the default home
                       HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE
               if the database has a non default home
                       HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HOMEyy
                               (yy the home number of your database)
           * ORACLE_SID
               HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE
       b) my_computer\properties\Environment
               declared in     - System Variables
                        or     - User Variables for user
       c) command prompt: input 'set local=TEST'
                               'set ORACLE_SID=TEST'
                       Remark: no space around the equal sign

       - to use svrmgrxx, local should not be set
       - if ORACLE_SID validation happens in this order
               1) registry
               2) my_computer\properties\Environment System Variables
               3) my_computer\properties\Environment User Variables
               4) command prompt
           The latest declaration is taken into account
               f.e. in registry:           ORACLE_SID=ORCL
                    at command prompt: set ORACLE_SID=TEST
               ==> TEST is going to be used
       - To see if any of these variables (local,ORACLE_SID) is
               set outside the registry, open a command prompt
               and type 'set Local'
                        'set ORACLE_SID'
               If the variable is not set outside the registry,
               ==> 'Environment variable local not defined'
               Otherwise
               ==> C:\>set ORACLE_SID
                   ORACLE_SID=or85
                   C:\>

1. Connect as internal to the instance you wish to remove.

      1A. Start Server Manager.

           From the Command Prompt
             * a1. Select Start\Run & Input 'Command'
                 or
               a2. Start\Programs\Command Prompt
               b.  Select OK.
               c.  Input 'set ORACLE_SID=TEST'
                     ? Remark: no spaces around the equal sign.
                     ? Make sure there is nowhere a local variable
                         defined.
                       To make sure:
                         - on Command Prompt: Input 'Set local'
                           => 'Environment variable local not defined'
                           ok
                         - registry: HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE
                           or HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HOMEyy
                                 (yy the home number of your database)
                         - right click my computer\properties\Environment
                                 no local variable declared in
                                         - System Variables
                                         - User Variables for user

               e.  svrmgrxx

           From the Windows NT Taskbar
           (check local and ORACLE_SID variable)
             a.  Select Start\Run.
             b.  Input svrmgrxx
             c.  Select OK.

           From Program Manager
           (check local and ORACLE_SID variable)
             a.  Select File\Run
             b.  Input svrmgrxx
             c.  Select OK.

      1B.  Input the following command at the SVRMGR> prompt:

          connect internal/<password>

      It should now state the following:

                 Connected

2.  Using the SPOOL and SELECT commands create a file that lists
     the full directory paths of the control, log and datafiles for TEST.
     The spool file will be used later to manually delete the files.

       SVRMGR>  spool <filename>
       SVRMGR>  select * from V$CONTROLFILE;
       SVRMGR>  select * from V$LOGFILE;
       SVRMGR>  select * from V$DATAFILE;
       SVRMGR>  spool off
       SVRMGR>  exit


3. Delete the instance, its services, pwd<SID>.ora and strt<SID>.ora.

      3A. Use the Taskbar or Program Manager to open a Command Prompt window.

           From the Windows NT Taskbar
               Select Start\Programs\Command Prompt.
                 or
             Select Start\Run & Input 'Command'

           From Program Manager
               Select the Main icon followed by the Command Prompt icon.

      3B.  Input the following command and press Enter.

             oradimxx -delete -sid TEST

4. Verify the instance was deleted.

      4A. Open and view the oradimxx.log.

           From the Windows NT Taskbar
              a.  Select Start\Programs\Windows NT Explorer.
              b.  Go to the orant\rdbmsxx directory.
              c.  Open the oradimxx.log file in Notepad.

           From File Manager
              a.  Open Program Manager and Select the Main icon followed by
the
                  File Manager icon.
              b.  Go to the orant\rdbmsxx directory.
              c.  Open the oradimxx.log in Notepad.


      4B.  The ordimxx.log file should read:

               Deleting instance...

               Instance deleted.

           If it does, exit Notepad, exit the Explorer (or File Manager),
and
         go to Step 5.  Else, refresh the oradimxx.log file periodically
           until it states
           "Instance deleted."  If refreshing the screen doesn't change the
           log, go to Step 5.

    Till 8.0.4 the Instance Manager had a Graphical User Interface where one     could verify if which instances exist on the server.     To display the GUI Instance Manager: type at the command prompt: ORADIMxx.

5. Verify the OracleStartTEST and OracleServiceTEST services were removed.

       For Oracle 8.1.x only the OracleServiceTEST existed

      5A. Open the Windows NT Services window.

           From the Windows NT Taskbar
              a.  Select Start\Settings\Control Panel.
              b.  Select the Services icon.

           From Program Manager
              a.  Select the Main icon.
              b.  Select the Control Panel icon.
              c.  Select the Services icon.

      5B.  Verify the following services are no longer present:

             OracleStartTEST and OracleServiceTEST.

           If they are, close the Services window, exit Control Panel,
           and go to Step 6 else to to Step 5C.

      5C.  Use the command line Instance Manager to manually delete the
           services.  Be sure to replace <service> with the name of the
           service as it appears in Control Panel\Services.

                oradimxx -delete -srvc <service1>, <service2>

      5D.  Repeat Steps 5A and 5B to verify the services were successfully
           removed.  If they have been deleted, close the Services Window,
           exit Control Panel, and go to Step 6.  If not, either refresh the
           Control Panel\Services Window periodically until they are
removed.
           Or, reboot the machine to force the removal of all services
           marked for deletion.

6.  Manually delete the control, log and data files using Explorer or File
     Manager.

     6A.  Print the spool file created in Step 2.
          1.  Open the spooled file in Notepad.
          2.  Select File\Print.
          3.  Exit Notepad.

     6B.  Find and delete the control files, log files, and
          data files from the directories specified in the
          spooled file.

     6C.  Delete the orant\database\initTEST.ora file.  Verify the
pwdTEST.ora
          (a hidden file) and strtTEST.ora files are deleted.  If not,
delete
          them.
     6D.  Go to the Orant\Rdbmsxx\Trace directory.  Delete all files
associated
          with the TEST instance.
     6E.  Exit the Explorer (or File Manager).

7.  Verify the ORACLE_SID parameter in the registry is set to an instance
     other than TEST

      CAUTION:  One should use caution in editing the registry.  Your system
                may not boot up if you inadvertently modify a critical
system
                parameter.  Before editing this file you may want to view
the
                'Help' in the registry.  Review the topics, 'Exporting all
or
                part of the registry to a text file', 'Importing some or all
of
                the registry', and 'Restoring the registry'.

      7A.  Open the Registry Editor.

           From the Windows NT Taskbar
              a.  Select Start\Run.
              b.  Input regedt32 or regedit
              c.  Select OK.

           From Program Manager
              a.  Select File\Run.
              b.  Input regedt32
              c.  Select OK.

      7B.  Select HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE.  A list of
           parameters should appear on the right pane.  In that list,
           locate ORACLE_SID.  If it's set to TEST, change it to another
SID.       7C. Exit the Registry Editor.

8. Check the environment variables if nothing refers to the SID

  1. Start\Settings\Control Panel\System
  2. Choose the Tab Environment
  3. Check the system variables and the user variables if nothing refers to the old SID (f.e. ORACLE_SID=TEST). If so change appropriately: delete the key or change it to another SID.
  4. The instance has been removed.

  Remark: The Database Assistant (8.0) and Database Configuration Assistant(8.1)
  tools can do step 1 to 6 in an automated and graphical way. .



 Copyright (c) 1995,1999 Oracle Corporation. All Rights Reserved. Legal Notices and Terms of Use.

David Thom <davidt_at_npsinc.com> wrote in message news:7C500B58DC32CC29.E384C5849FDEAC30.AB3B105660792AC5_at_lp.airnews.net... >
> We HAD a clean, running 8.0.5 on an NT 4.0 server, and decided to  de-install
> it to get a fresh start (it's a development server, and the Oracle  instance

> had been klugged-up with lots of trash definitions, etc).
>
> After an apparently clean un-install of everything,  and after a
 subsequent
> "clean" install, we can't even get simple stuff to work. For example, we > can't test service connectivity under the Net8 assistant without getting  an
> error saying that the error text for message 12705 could not be found (and
> why are we getting the 12705 message in the first place..the service
> definition looks fine).
>
> All symptoms point to a corrupted installation,  and so we would like to
> start over from scratch. But after more than one iteration through the
> de-install/install process using the Installer, it's clear that we're not
> getting back to a clean start.
>
> What are the manual steps involved in getting 8.0.5 completely
 uninstalled?
>
> David Thom
> NPSi Houston
>
>
>
Received on Thu Sep 07 2000 - 15:09:23 CDT

Original text of this message

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