Thursday, November 14, 2013

Silent Upgrade with In-Use Files Leaves Java Uninstalled (In-Progress)

This has been submitted to Oracle and entered as a bug into their bug tracking system under Bug Id: 9009448. This bug is not publicly available.

This issue is active. This page may be updated with additional information as it becomes available.

This issue was experienced when:
  • Java 7 Update 11 to Java 7 Update 25 Upgrade on Windows x64
  • Java 7 Update 25 to Java 7 Update 45 Upgrade on Windows x64
  • Java 7 Update 45 to Java 7 Update 51 Upgrade on Windows x64
    This document focuses on the Java 7 Update 25 to Java 7 Update 45 Upgrade on Windows x64.

Issue

When Java is upgraded using the silent switch (/s) with the installer executable and Java files are in-use, the following is experienced:
  • Java web sites and applets no longer work
  • Java version verification site showed no version installed
  • The previous version of Java was partially uninstalled from the file system
  • The previous version of Java was removed from Programs and Features (aka Add/Remove Programs)
  • The new version of Java was not installed on the file system
    * Java 7 Update 51: Files were installed in the Program Files folder, but missing from SysWOW64
  • The new version of Java was added to Programs and Features (aka Add/Remove Programs)
  • Java Control Panel applet is missing

What does this mean?

Most companies inventory a system using Programs and Features (aka Add/Remove Program) data. Moreover, most companies use patch software that detects installed versions that require patching. Both of these processes break when Java's installer causes this issue. The program shows as installed when the product is definitely not which will throw off installed totals, etc. Patching solutions will show the system as not requiring a patch or as even having the software.

Cause

The versions of Java were not packaged correctly to work when installations are performed silently. They neither take advantage of Windows Installer functionality nor address errors encountered. When an in-use file is encountered, the installation silently continues instead of rolling back.

This is different from installations that are not silent; during those installations the user is prompted to close the programs identified as having files in-use.

Additional Information

The executable is a wrapper that extracts a Windows Installer package. The Windows Installer package does not install the software, but instead places the installation files on the file system and runs Custom Actions to install Java.

When installing software on a given platform, a company must hire persons with the skill set to properly package software using technologies for that platform; in this case Windows Installer.

This issue is different, almost the exact opposite, of that described in JDK-7042296 : Silent Installations Break Java Installation, http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7042296, that was opened on 05/05/2011 and still has the status of Open and is Unresolved. This shows how much the vendor cares about their product and the persons/companies using it.

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\JavaSoft is populated with Java 7 Update 45 data.

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall is populated with Java 7 Update 45 data.

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\PendingFileRenameOperations is populated with Java 7 Update 45 data. This makes it impossible to install Java until the system is rebooted or the data for the value is modified to remove Java-specific entries.

Neither a repair nor an installation over the currently broken version can be performed. A full uninstall/install will be required.

Steps to Reproduce

Note: Java 7 Update 25 / Java 7 Update 45
  1. Install Java 7 Update 25
    (jre-7u25-windows-i586.exe /s /norestart /L %windir%\system32\LogFiles\jre-7u25-windows-i586_inst.log)
  2. Verify the installed Java web browser version
    1. Open https://www.java.com/en/download/installed.jsp?detect=jre
    2. Click Run when asked "Do you want to run this application?"
      Do not check the checkbox to "not show again"
    3. Version shows as Java 7 Update 25
    4. Close the web page.
  3. Verify the installed Java system version
    1. Open Java Control Panel (32-bit)
      (
      "%ProgramFiles% (x86)\Java\jre7\bin\javacpl.exe")
    2. Select the Java tab
    3. Select the User tab; version is 1.7.0_25
    4. Select the System tab; version is 1.7.0_25
    5. Close Java Conrol Panel (32-bit)
  4. Verify the installed Java executables
    1. Open a Command Prompt
    2. Type: DIR %WINDIR%\SysWOW64\java*
    3. Returns a list of Java executables
    4. Close Command Prompt
  5. Verify the installed Java in Programs and Features
    1. Open/Refresh Programs and Features in Control Panel
    2. Java 7 Update 25 is shown
    3. Close Programs and Features
  6. Verify the installed Java web browser version
    1. Open https://www.java.com/en/download/installed.jsp?detect=jre
    2. Do nothing when asked "Do you want to run this application?"
  7. Install Java 7 Update 45
    (
    jre-7u45-windows-i586.exe /s /norestart /L %windir%\system32\LogFiles\jre-7u45-windows-i586_inst.log)
  8. Review the installation log.
    (%windir%\system32\LogFiles\jre-7u45-windows-i586_inst.log)
    1. The log showed 1603 errors
      1. Must reboot to complete operation.
      2. Close that application and retry.
    2. The log showed the installation was successful.
      1. Windows Installer installed the product. Product Name: Java 7 Update 45. Product Version: 7.0.450. Product Language: 1033. Manufacturer: Oracle. Installation success or error status: 0.
  9. Close the web browser.
  10. Verify the installed Java web browser version
    1. Open https://www.java.com/en/download/installed.jsp?detect=jre
    2. Click Run when asked "Do you want to run this application?"
      Do not check the checkbox to "not show again"
    3. Version check errors
    4. Close the web page.
  11. Verify the installed Java system version
    1. Open Java Control Panel (32-bit)
      (
      "%ProgramFiles% (x86)\Java\jre7\bin\javacpl.exe")
    2. Select the Java tab
    3. Select the User tab; version is 1.7.0_25
    4. Select the System tab; version is 1.7.0_25
    5. Close Java Conrol Panel (32-bit)
  12. Verify the installed Java executables
    1. Open a Command Prompt
    2. Type: DIR %WINDIR%\SysWOW64\java*
    3. Returns File not found
    4. Close Command Prompt
  13. Verify the installed Java in Programs and Features
    1. Open/Refresh Programs and Features in Control Panel
    2. Java 7 Update 45 is shown
    3. Close Programs and Features

No comments:

Post a Comment