JDK-8040930 : [MSI] Some files left after uninstalled 32bit JRE if 64bit JRE exists
  • Type: Bug
  • Component: install
  • Sub-Component: install
  • Affected Version: 8u20,9
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_7
  • CPU: x86
  • Submitted: 2014-04-18
  • Updated: 2014-08-18
  • Resolved: 2014-05-22
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8 JDK 9
8u20Fixed 9 b22Fixed
Description
1. Install 32bit JRE using MSI bundle on 64bit OS.
2. Install 64bit JRE using MSI bundle on 64bit OS.
3. Uninstall 32bit JRE using msiexec.exe /qn /x {GUID}
4. Check the 32bit JRE home folder.

Expected:
All files of 32bit JRE are removed

Actual:
Some files left after uninstall

C:/Program Files (x86)/Java/jre1.9.0
C:/Program Files (x86)/Java/jre1.9.0/bin
C:/Program Files (x86)/Java/jre1.9.0/bin/client
C:/Program Files (x86)/Java/jre1.9.0/bin/client/classes.jsa
C:/Program Files (x86)/Java/jre1.9.0/lib
C:/Program Files (x86)/Java/jre1.9.0/lib/charsets.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/deploy.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/javaws.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/jsse.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/plugin.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/rt.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/applet
C:/Program Files (x86)/Java/jre1.9.0/lib/ext
C:/Program Files (x86)/Java/jre1.9.0/lib/ext/jfxrt.jar
C:/Program Files (x86)/Java/jre1.9.0/lib/ext/localedata.jar

The same issue occurs if install and uninstall 64bit JRE first.

Comments
Verified with JDK9 b23
18-07-2014

PIT verified with 9 b18
17-06-2014

Reopening ... still reproducible with 8u20 PIT b14. Test system info sent to dev. Steps: 1. install 32 bit jre 2. then install 64 bit jre 3. uninstall 32 bit jre using following command msiexec /qn /x {26A24AE4-039D-4CA4-87B4-2F83218020F0} 4. Check C:\Program Files (x86)\Java directory is removed Expected Result: The Java directory should be removed. Actual Result: bin and lib directories still found under the Java directory
13-05-2014

I'm able to reproduce now. It only happens when you install jre 32 *and* 64 enterprise JREs, and then uninstall one of them. I believe the problem is the fact that the MSI one-file-per-components have identical names between 32 and 64. In the MSI RemoveFile table, I see that all of the entries for these files are CompNum1000. The same would be for both 32 and 64 bit msi's. So I think we need to have our scripts add a 32 or 64 to the Component names. Instead of CompNum1000, it should be Comp32Num1000 and Comp64Num1000. I believe the The ComponentID's will also need a 32 vs 64 difference.
13-05-2014

We need a test vm info where this issue is reproducible.
07-05-2014

I tried reproducing this again on different Windows 7/Vista VMs , but was not able to reproduce this issue. Please provide a test vm (machine name/login/pwd credentials ) where the issue is seen. I will reproduce the issue there and audit logs to see what could be causing the files left behind.
06-05-2014

I can still reproduce this bug on my win7 x64 machine. I used the PIT and nightly builds of 1.9.0 I just installed 32bit MSI bundle then 64bit MSI bundle. Then I uninstalled 32bit JRE using command msiexec /qn /x {26A24AE4-039D-4CA4-87B4-2F83219000F0} Then I checked the C:\Program Files (x86)\Java\jre1.9.0 folder and found there are some files left. I did not run any applet when uninstalling. PIT: http://oklahoma.us.oracle.com/arc/ds_build/1.9.0/pit/b11/ Nightly: http://oklahoma.us.oracle.com/arc/ds_build/1.9.0/nightly/2014-04-29_00-31-16/
30-04-2014

I was not able to reproduce this issue either. Tried both latest nightly and promoted builds.
29-04-2014

Bug submitters: Please add info like where you got the exe from? Was it a nightly? pit? promotion?!? need full url/path to exe I assume if they were running an applet, they would have specified in the steps to repro. So I don't think it's that. The file list that doesn't get removed are the specific files that are created during the install (via unpack200.exe calls, javaw.exe -XShare, etc). For that reason, the MSI doesn't know about them, so we need to add entries to the removefile table for them. It looks more like the MSI's remove file table didn't have them listed at the time of this particular build. Anyways, we can't reproduce with the latest nightly builds. So I'm closing as not reproducible.
29-04-2014

Looks like the uninstall is being run silently, and there was an active plugin. The MSI should invoke a FIU type mechanism if run in non-silent mode, and fail gracefully if in silent mode, and encounters locked files.
29-04-2014

Affected tests: MSI/MSI003-001-001 MSI/MSI003-001-002
18-04-2014