JDK-6617263 : cannot start java control panel while initial background downloader is running
  • Type: Bug
  • Component: deploy
  • Sub-Component: deployment_toolkit
  • Affected Version: 6u5
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: windows
  • CPU: x86
  • Submitted: 2007-10-15
  • Updated: 2010-09-08
  • Resolved: 2008-01-31
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.
6u10 b06Fixed
While the initial background downloader is running (background downloader launched by java installer), Launching control panel gives "Main Class Not Found.Program Will exit".(KernelDownloadUrl is used) 
This error is coming in XP also.(, vnc password :vnc )

I can reproduce the problem in my XP machine too.  It seems like it's caused by:

java.lang.IllegalStateException: error acquiring mutex
       at sun.jkernel.Mutex.acquire(Native Method)
       at sun.jkernel.Bundle.loadReceipts(Unknown Source)
       at sun.jkernel.Bundle.updateState(Unknown Source)
       at sun.jkernel.Bundle.isInstalled(Unknown Source)
       at sun.jkernel.DownloadManager.doGetBootClassPathEntryForResource(Unknow
n Source)
       at sun.jkernel.DownloadManager.access$500(Unknown Source)
       at sun.jkernel.DownloadManager$3.run(Unknown Source)
       at java.security.AccessController.doPrivileged(Native Method)
       at sun.jkernel.DownloadManager.getBootClassPathEntryForResource(Unknown
       at sun.jkernel.DownloadManager.getBootClassPathEntryForClass(Unknown Sou
       at java.lang.ClassLoader.findBootstrapClass(Native Method)
       at java.lang.ClassLoader.findBootstrapClass0(Unknown Source)
       at java.lang.ClassLoader.loadClass(Unknown Source)
       at java.lang.ClassLoader.loadClass(Unknown Source)
       at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
       at java.lang.ClassLoader.loadClass(Unknown Source)
       at java.lang.ClassLoader.loadClassInternal(Unknown Source)

EVALUATION This is caused by the java control panel process cannot create the native mutex for bundle install. The background downloader launched by the java installer is running as SYSTEM user. It will create native mutex while installing bundles. Now while the downloader is running, and we invoke the java control panel or any other java process, it needs to download and install bundle as well. If it happens that it tries to create a mutex that is current held by the background downloader process, the native CreateMutex call will fail with ERROR_ACCESS_DENIED, because it does not have priviledge to access the mutex object created by SYSTEM. Therefore we failed to install the necessary bundle, and fail to launch java control panel.

SUGGESTED FIX Create the native mutex with a NULL DACL security attribute, which will allows all access to the mutex object. Testcase: http://web-east.east.sun.com/deployment/www/tests/1.6.0_05/6617263/ ================================ webrev: http://sa.sfbay.sun.com/projects/deployment_data/6u5/6617263.0