/* Copyright (c) Oracle Corporation 1995. All Rights Reserved */ /***************************************************************************** NAME rsf80.vrf - WinNT V3 installation verification script for the Required Support Files (RSF). DESCRIPTION This script checks dependencies and environment settings for installation of the Windows NT RSF. OWNER Tony Rodgers MODIFIED MM/DD/YY Reason mmckerle 04/28/98 Modified code to check for RDBMS only up to the first 3 digits ekhor 11/24/97 reboot to complete install for WIN_95 if msvc dlls are in used rpingte 12/11/96 Add trace dependency mmacdona 03/13/96 Make Win32 Common ljiang 07/20/95 7.2 syau 07/01/94 7.1.3 HA! 04/28/94 7.1.2 and 3.0.10.2 trodgers 10-APR-92 Created. *****************************************************************************/ { { doit = execute("%installer_home%\%operating_system%.vrf"); } [ 'UNBOUND_VARIABLE: { required_version = product_version(ntinstver); temp = explode(required_version,"."); required_version = implode(list(first(temp),first(rest(temp)), first(rest(rest(temp))), first(rest(rest(rest(temp))))),"."); signal('failure,instantiate(nls("instver_too_early1","The version of the Installer currently running is %%installer_version%%. The installation you have chosen requires version %%required_version%% or later. Please run version %%required_version%% or later in order to perform this installation."))); } ] if (doit) { /*********************************************************************** Set the VRF-INS script "ratchet" ***********************************************************************/ vrf_ratchet = "8.0.5.0.0"; /*** Variables used in force installing Sqlnet client and trace server ***/ client_prod = w32netclt80; client_name = "w32netclt80"; trace_prod = w32tracesvr80; trace_name = "w32tracesvr80"; /*********************************************************************** Bind path variables... ************************************************************************/ { set_rdbms80 = FALSE; rdbms80 = translate("RDBMS80", ora_config, product_filename(current_product)); if (not(exists(rdbms80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { rdbms80 = "%oracle_home%\RDBMS80"; set_rdbms80 = TRUE; } ] { set_plsql80 = FALSE; plsql80 = translate("PLSQL80", ora_config, product_filename(current_product)); if (not(exists(plsql80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { plsql80 = "%oracle_home%\PLSQL80"; set_plsql80 = TRUE; } ] { set_core40 = FALSE; core40 = translate("CORE40", ora_config, product_filename(current_product)); if (not(exists(core40))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { core40 = "%oracle_home%\CORE40"; set_core40 = TRUE; } ] { set_nlsrtl33 = FALSE; nlsrtl33 = translate("NLSRTL33", ora_config, product_filename(current_product)); if (not(exists(nlsrtl33))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { nlsrtl33 = "%oracle_home%\NLSRTL33"; set_nlsrtl33 = TRUE; } ] { set_ora_nls = FALSE; ora_nls = translate("ORA_NLS33", ora_config, product_filename(current_product)); if (not(exists(ora_nls))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { ora_nls33 = "%nlsrtl33%\DATA"; set_ora_nls = TRUE; } ] { set_pro80 = FALSE; pro80 = translate("PRO80", ora_config, product_filename(current_product)); if (not(exists(pro80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { pro80 = "%oracle_home%\PRO80"; set_pro80 = TRUE; } ] { set_trace80 = FALSE; otrace80 = translate("OTRACE80", ora_config, product_filename(current_product)); if (not(exists(otrace80))) signal('UNBOUND_ENVIRONMENT_VARIABLE); } [ 'OS_ERROR,'INVALID_FILE_NAME,'FILE_NOT_FOUND, 'PERMISSION_DENIED,'UNBOUND_ENVIRONMENT_VARIABLE: { otrace80 = "%oracle_home%\OTRACE80"; set_trace80 = TRUE; } ] winsys = windows_system_directory(); windir = windows_directory(); /* The following code was added for use with OCSM Compliance. */ /* Get the Windows (95 or NT) system directory, not the whole */ /* path, just the name of the directory. It is called SYSTEM */ /* in Win95 and SYSTEM32 in NT (although NT has SYSTEM also). */ /* This variable is used in RSF80.MAP in the shrdll group. */ tmp_list = explode(winsys, "\"); while(not(empty(tmp_list))) { sysdir = first(tmp_list); tmp_list = rest(tmp_list); } /*********************************************************************** Bind string variables & prompt strings... ***********************************************************************/ installing_scripts = nls("installing_scripts", "Installing %%product_label%% Scripts..."); installing_dlls = nls("installing_dlls", "Installing %%product_label%% Dynamic Link Libraries..."); installing_msbs = nls("installing_msbs", "Installing %%product_label%% Message Files..."); installing_sql = nls("installing_sql", "Installing %%product_label%% SQL Scripts..."); installing_nlsdata = nls("installing_nlsdata", "Installing %%product_label%% NLS data files..."); modifying_config = nls("modifying_config", "Modifying NT Registry..."); registering = nls("registering","Registering %%product_label%%..."); inUse_prompt = nls("inUse_prompt" , "Some Oracle products are currently in use. Please stop all Windows NT services and quit applications that are using Oracle's products before proceeding with this install.%carriage_return%%carriage_return%Press OK to continue the installation once the services and applications have been stopped, or press Cancel to abort the installation."); inUse_content = nls("inUse_content", "Stop Oracle Applications"); inUse_help = nls("inUse_help" , "Oracle Required Support Files are being used. Please stop Oracle applications and services before continuing to install. Use the Oracle utility, oradim80, or use the Windows NT service control panel to stop all Oracle Services that are running on this machine."); rsf_note = nls("rsf_note","The Oracle Installer is unable to copy some Microsoft Distributable Dlls into your system directory because they are currently in use. You need to reboot your machine in order to complete the installation of Oracle Required Support Files."); #rename_dll=nls("rename_dll","The 805 files that will be installed by this version of Required Support Files into the ORACLE_HOME\bin directory are functionally different from the files by the same name that were shipped with 8.0.5.0.0 version .The 805 names have been used for naming compatibility only."); prev805_install_message = nls("prev805_install_message","During installation of 8.0.6 some Required Support Files ( RSFs ) installed into the ORACLE_HOME\bin directory are labelled '805'.These files are required for successful operation of 8.0.6 and are DIFFERENT from similarly named files included with the 8.0.5 release.Both sets of RSFs can co-exist on the same machine but must be installed into different Oracle Homes.Application users must use the appropriate RSFs for the version of database for which the application relies upon.Do not delete either set of RSFs if you intend to run both 8.0.5 and 8.0.6 databases on the same machine."); noprev805_install_message = nls("noprev805_install_message","During the installation of 8.0.6,some Required Support Files ( RSFs ) installed into the ORACLE_HOME\bin directory are labeled '805'.These files contain functionality specifically associated with the 8.0.6 release.The 805 names have been used for backward compatibility purposes only."); /*********************************************************************** Return total size of files depending upon which options were selected for installation... ************************************************************************/ if (platform() == "nt") { /* Stop services */ make_directory("%rdbms80%"); /*** Stopping of services will take place by executing the stopServices.vrf script ***/ { execute("%product_home%\stopsrvc.vrf"); } [ 'DEFAULT: continue(); ] /* Determine the database SID for this home, since it is embedded in DB service names. */ /*** Old stop services code is commented out in place of algorithm in stopServices.vrf { db_sid = translate("ORACLE_SID", "$ORACLE"); } [ 'DEFAULT: db_sid = "ORCL"; ] { nt_stop_service("oracle%ORACLE_HOME_NAME%tnslistener80"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclenmplistener%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracle%ORACLE_HOME_NAME%tcplistener"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclestart%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracle%ORACLE_HOME_NAME%webassistant"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracleservice%db_sid%"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oracleservice"); } [ 'DEFAULT: continue(); ] { nt_stop_service("oraclenmplistener"); } [ 'DEFAULT: continue(); ] End old code to stop services ***/ } /* 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_copy1", "Installation 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", "Installation terminated. Please stop all Oracle services before installing.")); '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_copy2", "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(); ] /*** ****************************************************************************************************** ***/ /*** This section of code informs the user of a possible error if they are installing the 8.0.x RSF over ***/ /*** an existing earlier installation of the 8.0.x RSF. If there is a matching Database installed already, ***/ /*** then installing this could break the old database. ***/ /*** We use the following algorithm to determine whether to inform the user of possible error: ***/ /*** - Is the DB being installed in the current session? ***/ /*** - Yes: Done. (Software is being replaced anyway - no problem). ***/ /*** - No: Is RDBMS80 registered in the current home? ***/ /*** - No: Done. (No DB means we won't break it.) ***/ /*** - Yes: Does the third digit of its version match the version of the RSF? ***/ /*** (Note: We have already determined that we have an 8.0.x database - comparing the ***/ /*** third digit will suffice) ***/ /*** - Yes: Done (No Problem.) ***/ /*** - No: Display dialog. ***/ /*** ****************************************************************************************************** ***/ server_side = TRUE; /*** Assume the database is packaged with the RSF ***/ db_selected = FALSE; /*** Assume the database has not been selected to be installed ***/ /*** We need to get the right label for the database depending on which platform we are on ***/ if(platform() == "nt") { { db_prod = ntrdbms80; } ['UNBOUND_VARIABLE: server_side = FALSE;] /*** we are installing a client of some type ***/ db_label = "ntrdbms80"; } else # We are running Windows 95.... { { db_prod = w95rdbms80; } ['UNBOUND_VARIABLE: server_side = FALSE;] /*** we are installing a client of some type ***/ db_label = "w95rdbms80"; } rsf_label = "w32rsf80"; /*** Define messages ***/ brokenProduct_prompt = nls("brokenProduct_prompt", "Important: Oracle has detected a release %registeredRdbmsVersion% database in the Oracle home in which you are installing. If you proceed with installation, Required Support Files %currentRSFVersion% will be installed over Required Support Files %registeredRSFVersion% and break your existing database. If you wish to keep this database intact, we recommend installing into a new Oracle home. See the Getting Started guide provided with this release for more information on Multiple Oracle Homes.%carriage_return%%carriage_return%Click [Yes] if you want to continue installation.%carriage_return%Click [No] if you want to exit Oracle Installer."); brokenProduct_content = nls("brokenProduct_content", "Database Conflict Detected"); if(server_side) { if((member(selected_products, db_prod)) || (member(products_for_installation, db_prod))) db_selected = TRUE; } if(not(db_selected)) { if(registered(db_label)) { registeredRdbmsVersion = registry_version(registration(db_label)); #registeredRSFVersion = registry_version(registration(rsf_label)); currentRSFVersion = product_version(current_product); rdbmsVersionNumbers = explode(registeredRdbmsVersion, "."); rsfVersionNumbers = explode(currentRSFVersion, "."); /*** Extract the third digit from the RDBMS and RSF and compare ***/ rdbmsThirdDigit = first(rest(rest(rdbmsVersionNumbers))); rsfThirdDigit = first(rest(rest(rsfVersionNumbers))); if(rdbmsThirdDigit != rsfThirdDigit) { goAhead = yesno_dialog(instantiate(brokenProduct_prompt), FALSE, brokenProduct_content, 'NOHELP, 'NOCANCEL); if(not(goAhead)) signal('FAILURE, nls("install_failure", "Installation terminated at user request.")); } } } /* This block is for showing a proper message regarding the renamed dlls depending on the Oracle_Home structure in the machine . */ home_list = all_homes(); extract(home_list, oracle_home_info); #current_product_installations = list(); homechk = TRUE; rsfThirdDigit = 0; while(not(empty(home_list))) { hm = first(home_list); if (registered(product_name(current_product), hm)) { registry = registration(product_name(current_product), hm); installed_version = registry_version(registry); existingversion = explode(installed_version,"."); rsfThirdDigit = first(rest(rest(existingversion))); if (rsfThirdDigit == 5) homechk = FALSE; } if(homechk) home_list = rest(home_list); else home_list=list(); } ['UNBOUND_VARIABLE: {information_dialog(instantiate(noprev805_install_message),'NOCANCEL);} ] /* */ if (rsfThirdDigit == 5) information_dialog (instantiate(prev805_install_message),'NOCANCEL); else information_dialog(instantiate(noprev805_install_message),'NOCANCEL); /* reminder: we forget deinstl70, deinstl71 here */ total = 0; /* Sum commdll group only if it is an earlier version, or doesn't exist. */ commdll_size = 0; overwrite_mode = 'UPDATE; commdll_size = sum(commdll); /* Set mode back to default. */ overwrite_mode = 'ALWAYS; /*** Force install trace and sqlnet client and sum up copy groups ***/ return(total + commdll_size + verify(trace_prod) + verify(client_prod) + sum(deinstl,dll,msvcdll,mfcdll,msg,nls_abbreviation,sql,nlsdata)); } else { refresh_map_file = FALSE; return(0); } }