/* Copyright (c) Oracle Corporation 1995. All Rights Reserved */ /***************************************************************************** NAME rsf80.dei - WinNT V3 de-installation script for ORACLE Required Support Files. DESCRIPTION This script removes the Windows NT ORACLE RSF files and un-registers the product. OWNER Tony Rodgers MODIFIED DD-MMM-YY Reason mmacdona 03/13/96 Make Win32 Common ljiang 07/21/95 7.2 syau 07/01/94 7.1.3 HA! 04/29/94 7.1.2 and 3.0.10.2 trodgers 01-APR-92 Created. *****************************************************************************/ { { doit = execute("%installer_home%\%operating_system%.dei"); } [ 'UNBOUND_VARIABLE: signal('failure,instantiate(nls("instver_too_early2","The version of the Installer currently running is %%installer_version%%. The product(s) you have chosen to deinstall were installed with a later version of the Installer. Please use a later version of the Installer to deinstall these product(s)."))); ] if (doit) { /********************************************************************** Ensure that the necessary environment variables are bound **********************************************************************/ { rdbms80 = translate("rdbms80", ora_config, registry_filename(current_registry)); if (not(exists(rdbms80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "rdbms80"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] { plsql80 = translate("plsql80", ora_config, registry_filename(current_registry)); if (not(exists(plsql80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "plsql80"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] { core40 = translate("core40", ora_config, registry_filename(current_registry)); if (not(exists(core40))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "core40"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] { pro80 = translate("pro80", ora_config, registry_filename(current_registry)); if (not(exists(pro80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "pro80"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] { nlsrtl33 = translate("nlsrtl33", ora_config, registry_filename(current_registry)); if (not(exists(nlsrtl33))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "nlsrtl33"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] { otrace80 = translate("otrace80", ora_config, registry_filename(current_registry)); if (not(exists(otrace80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { variable = "otrace80"; information_dialog(instantiate(deinstall_prompt02), instantiate(deinstall_content02), instantiate(deinstall_help02)); doit = FALSE; } ] } if (doit) { /********************************************************************** Bind all NLS deinstall strings here... **********************************************************************/ unregistering = nls("unregistering","Unregistering %%registry_label%%..."); deinst_sql = nls("deinst_sql","Deinstalling %%registry_label%% SQL Scripts..."); deinst_msb = nls("deinst_msb","Deinstalling %%registry_label%% Message Files..."); deinst_dll = nls("deinst_dll","Deinstalling %%registry_label%% Dynamic Link Libraries..."); deinst_script = nls("deinst_script","Deinstalling %%registry_label%% Installation Scripts..."); /********************************************************************** Continue with the deinstallation **********************************************************************/ ui_product(registry_label); if (platform() == "nt") { /*********************** stop all the services **********************/ /* Determine the database SID for this home, since it is embedded in DB service names. */ { db_sid = translate("ORACLE_SID", "$ORACLE"); } [ 'DEFAULT: db_sid = "ORCL"; ] { nt_stop_service("oracle%ORACLE_HOME_SERVICE%tnslistener80"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclenmplistener%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracle%ORACLE_HOME_SERVICE%tcplistener"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclestart%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracleservice%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracleservice"); /* for 70 */ } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclenmplistener"); /* for 70, ? */ } [ 'DEFAULT: continue(); ] } /* check to see if all of the other oracle services are shutdown */ permit_retry_operations = FALSE; /* this should be the default */ { copy_file("%oracle_home%\bin\oraspawn.dll", "%oracle_home%\bin\oraspawn.sav"); } [ 'FILE_NOT_FOUND,'INVALID_FILE_NAME: continue(); 'READ_ERROR,'WRITE_ERROR: signal('FAILURE, nls("failure_of_copy3", "Deinstallation terminated because %oracle_home%\bin\oraspawn.dll could not be copied.")); ] { move_file("%oracle_home%\bin\oraspawn.sav", "%oracle_home%\bin\oraspawn.dll"); } [ 'OS_ERROR: signal('FAILURE, nls("failure_of_service", "Deinstallation terminated. Please stop all Oracle services before deinstalling.")); 'DEFAULT: continue(); ] { copy_file("%oracle_home%\bin\ora80dis.dll", "%oracle_home%\bin\ora80dis.sav"); } [ 'FILE_NOT_FOUND,'INVALID_FILE_NAME: continue(); 'READ_ERROR,'WRITE_ERROR: signal('FAILURE, nls("failure_of_copy4", "Installation terminated because %oracle_home%\bin\ora80dis.dll could not be copied.")); ] { move_file("%oracle_home%\bin\ora80dis.sav", "%oracle_home%\bin\ora80dis.dll"); } [ 'OS_ERROR: signal('FAILURE, nls("failure_of_service", "Installation terminated. Please stop all Oracle services before installing.")); 'DEFAULT: continue(); ] { copy_file("%oracle_home%\bin\otrace80.dll", "%oracle_home%\bin\otrace80.sav"); } [ 'FILE_NOT_FOUND,'INVALID_FILE_NAME: continue(); 'READ_ERROR,'WRITE_ERROR: signal('FAILURE, nls("failure_of_copy5", "Deinstallation terminated because %oracle_home%\bin\otrace80.dll could not be copied.")); ] { move_file("%oracle_home%\bin\otrace80.sav", "%oracle_home%\bin\otrace80.dll"); } [ 'OS_ERROR: signal('FAILURE, nls("failure_of_service_d", "Deinstallation terminated. Please stop all Oracle services before deinstalling.")); 'DEFAULT: continue(); ] /************************** remove files ****************************/ remove(nlsdata); if (not(registered("ntrsf72")) && not(registered("w32rsf73"))) { ui_action(instantiate(deinst_sql)); remove(sql); } ui_action(instantiate(deinst_msb)); remove(msg); ui_action(instantiate(deinst_dll)); remove(dll); remove(olddll); if (not(registered("ntrsf72")) && not(registered("w32rsf73"))) remove(commdll); /***************************** modify registry *************************/ if (not(registered("ntrdbms80")) && not(registered("w32util80"))) modify("RDBMS80","",ora_config,registry_filename(current_registry)); if (not(registered("w32util80"))) modify("PLSQL80","",ora_config,registry_filename(current_registry)); /* Modification (rxfernan JUN-97): commented out because PRO C needs this value. modify("PRO80","",ora_config,registry_filename(current_registry)); */ modify("CORE40","",ora_config,registry_filename(current_registry)); modify("NLSRTL33","",ora_config,registry_filename(current_registry)); modify("ORA_NLS33","",ora_config,registry_filename(current_registry)); /***************************** unregister ******************************/ /* First, unreference any dependent products. */ if(registered("w32traceSvr80")) { dependent = registration("w32traceSvr80"); unreference( dependent, current_registry); } if(registered("w32netclt80")) { dependent = registration("w32netclt80"); unreference( dependent, current_registry); } /* Next, unregister the current product. */ ui_action(instantiate(unregistering)); unregister(current_registry); /* Finally, deinstall the dependent products. */ if(registered("w32traceSvr80")) { dependent = registration("w32traceSvr80"); deinstall( dependent ); } if(registered("w32netclt80")) { dependent = registration("w32netclt80"); deinstall( dependent ); } ui_action(instantiate(deinst_script)); remove(deinstl); } }