United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6651964 PIP install removes bin\msvcr71.dll, "Error loading: C:\Program Files\Java\jre6\bin\client\jvm.dll"
JDK-6651964 : PIP install removes bin\msvcr71.dll, "Error loading: C:\Program Files\Java\jre6\bin\client\jvm.dll"

Details
Type:
Bug
Submit Date:
2008-01-17
Status:
Closed
Updated Date:
2010-09-17
Project Name:
JDK
Resolved Date:
2008-02-21
Component:
install
OS:
windows_xp
Sub-Component:
install
CPU:
x86,generic
Priority:
P2
Resolution:
Fixed
Affected Versions:
beta,6u10
Fixed Versions:
6u10 (b12)

Related Reports
Backport:
Duplicate:
Relates:

Sub Tasks

Description
C:\Program Files\Java\jre6\bin\MSVCR71.dll is getting deleted during 6u11 or 6u12 patch in place.

Symptoms reported by Rakesh:
"Error loading: C:\Program Files\Java\jre6\bin\client\jvm.dll" when Patch-in-Place from 6u10 to 6u11 using 6u10 b10 PIT build.
http://sqindia.india/disk17/deployment/rakesh/pip/logs/Win2003/error.jpg

Logs
http://sqindia.india/disk17/deployment/rakesh/pip/logs/Win2003/ 


Systems with MSVCR71.dll installed to the Windows system directories seem to work.

                                    

Comments
EVALUATION

RemoveInstalledFiles() is being called during a patch.

This is related to code added for CR 6622174 java/install need to remove msvcr71.dll from the RemoveFile table
                                     
2008-01-17
SUGGESTED FIX

webrev: http://sa.sfbay.sun.com/projects/deployment_data/6u10/6651964.0 

UninstallJRE() and UninstallJavaRegSet() now passed a variable so it knows whether its called during JRE uninstall, JRE install, or JDK uninstall.
MSIInstallJRE() calls UninstallJRE() with DURING_JRE_INSTALL.
MSIUninstallJRE() calls UninstallJRE() with DURING_JRE_UNINSTALL.
MSIUninstallSDK() calls UninstallJavaRegSet() with DURING_JDK_UNINSTALL.

Only call RemoveInstalledFiles() when DURING_JRE_UNINSTALL.
I've seen tests where msvcr71.dll could not be deleted by RemoveInstalledFiles() without sleeping 3 seconds after UninstallJQS() was called.
Added logic to sleep and retry RemoveInstalledFiles() for up to 6 seconds before leaving the file and continuing on.

java_install_reg.log may contain:
-- Start in UninstallJavaRegSet --
Service stopped successfully
JQS unregistered OK.
-- RemoveInstalledFiles: DeleteFile(C:\Program Files\Java\jre6\bin\msvcr71.dll) failed. (GetLastError=5)
-- Retrying RemoveInstalledFiles
-- End in UninstallJavaRegSet --
                                     
2008-01-24



Hardware and Software, Engineered to Work Together