This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 39753 - "The specified J2SDK Home is invalid" error
Summary: "The specified J2SDK Home is invalid" error
Status: RESOLVED WORKSFORME
Alias: None
Product: installer
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: mslama
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-02-08 05:17 UTC by oneway
Modified: 2005-03-21 11:53 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description oneway 2004-02-08 05:17:45 UTC
Trying to install NB 3.6.beta. Have J2SDK
installed in the "C:\Program Files\Sun\j2sdk1.4.2"

NB can't find the JDK, I point to it (in the J2SDK
Selection panel of the installation wizard), I get
"The specified J2SDK Home is invalid" error.

Tried also "C:\Progra~1\Sun\j2sdk1.4.2", the same
effect.

Reinstalled JDK (without removing current
installation), the same error.

Currently running NB3.5 without any problems.

-----------------------------------
WinXP SP1 Build 2600

>java -version
java version "1.4.2"
Java(TM) 2 Runtime Environment, Standard Edition
(build 1.4.2-b28)
Java HotSpot(TM) Client VM (build 1.4.2-b28, mixed
mode)
Comment 1 George Hernandez 2004-02-08 06:16:08 UTC
After investigating a problem similar to this on a mac, this issue may
be the same. If the user could verify that there is a directory in
your j2se installation call "jre". If this directory is missing, the
installer will think your j2se installation is invalid and refuse to
accept your j2se.
Comment 2 oneway 2004-02-08 11:26:30 UTC
Yes, indeed there is "jre" directory within the J2SDK installation.
JRE is also installed separately into the "C:\Program
Files\Java\j2re1.4.2".
Comment 3 oneway 2004-02-08 21:06:40 UTC
>java -Dis.debug=1 -jar NetBeansIDE-release36-Beta-setup.jar
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SetInstallSystemPropertiesAction, dbg, isAdmin: yes
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SetInstallSystemPropertiesAction, dbg, backupDirName:
 backup
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SetInstallSystemPropertiesAction, dbg, Checking Win32
 Registry ...
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SetInstallSystemPropertiesAction, dbg, skipAdmin: tru
e
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SetInstallSystemPropertiesAction, dbg, continueInstal
lation: true
(Feb 8, 2004 3:54:43 PM), Setup.product.install,
com.sun.installer.SystemPropertyWizardBeanCondition, dbg, Condition for
 continueInstallation : (true,true) -> true
rpmspec.debug - linux product service - host supports RPM. Returning
system compatibility-0
GenericUnixFileServiceImpl returns compatibility: 0
(Feb 8, 2004 3:54:44 PM), Setup.product.install,
com.installshield.wizard.platform.win32.Win32PPKRegistryServiceImpl, db
g.registry, reading VPD from C:\WINDOWS\vpd.properties
(Feb 8, 2004 3:54:44 PM), Setup.product.install,
com.sun.installer.SystemPropertyWizardBeanCondition, dbg, Condition for
 continueInstallation : (true,true) -> true
(Feb 8, 2004 3:54:48 PM), Setup.product.install,
com.sun.installer.SystemPropertyWizardBeanCondition, dbg, Condition for
 continueInstallation : (true,true) -> true
(Feb 8, 2004 3:54:48 PM), Setup.product.install,
com.sun.installer.SystemPropertyWizardBeanCondition, dbg, Condition for
 continueInstallation : (true,true) -> true
(Feb 8, 2004 3:54:48 PM), Setup.product.install,
com.sun.installer.LicenseAgreementPanel, dbg, BCL resName = beanLicense
AgreementPanel_license_file_en
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Current JVM ...C:\Prog
ram Files\Java\j2re1.4.2
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Java
\j2re1.4.2
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Java
\j2re1.4.2\jre
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Win32 Registry ...
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Sun\
j2sdk1.4.2
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Sun\
j2sdk1.4.2\jre
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Exists: C:\Program Files\Sun\j2
sdk1.4.2\jre
CreateProcess: C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe -version
error=193
java.io.IOException: CreateProcess: C:\Program
Files\Sun\j2sdk1.4.2\bin\java.exe -version error=193
        at java.lang.Win32Process.create(Native Method)
        at java.lang.Win32Process.<init>(Unknown Source)
        at java.lang.Runtime.execInternal(Native Method)
        at java.lang.Runtime.exec(Unknown Source)
        at java.lang.Runtime.exec(Unknown Source)
        at com.sun.installer.RunCommand.execute(RunCommand.java:56)
        at com.sun.installer.RunCommand.execute(RunCommand.java:47)
        at
com.sun.installer.JDKSearchAction.getJVMInfo(JDKSearchAction.java:302)
        at
com.sun.installer.JDKSearchAction.checkJdkHome(JDKSearchAction.java:264)
        at
com.sun.installer.JDKSearchAction.findWindowsJDK(JDKSearchAction.java:112)
        at
com.sun.installer.JDKSearchAction.execute(JDKSearchAction.java:78)
        at
com.installshield.wizard.RunnableWizardBeanContext.run(RunnableWizardBeanContext.java:21)
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, NPE: java.lang.NullPointerExcep
tion
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Sun\
j2sdk1.4.2
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\Program Files\Sun\
j2sdk1.4.2\jre
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Exists: C:\Program Files\Sun\j2
sdk1.4.2\jre
CreateProcess: C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe -version
error=193
java.io.IOException: CreateProcess: C:\Program
Files\Sun\j2sdk1.4.2\bin\java.exe -version error=193
        at java.lang.Win32Process.create(Native Method)
        at java.lang.Win32Process.<init>(Unknown Source)
        at java.lang.Runtime.execInternal(Native Method)
        at java.lang.Runtime.exec(Unknown Source)
        at java.lang.Runtime.exec(Unknown Source)
        at com.sun.installer.RunCommand.execute(RunCommand.java:56)
        at com.sun.installer.RunCommand.execute(RunCommand.java:47)
        at
com.sun.installer.JDKSearchAction.getJVMInfo(JDKSearchAction.java:302)
        at
com.sun.installer.JDKSearchAction.checkJdkHome(JDKSearchAction.java:264)
        at
com.sun.installer.JDKSearchAction.findWindowsJDK(JDKSearchAction.java:112)
        at
com.sun.installer.JDKSearchAction.execute(JDKSearchAction.java:78)
        at
com.installshield.wizard.RunnableWizardBeanContext.run(RunnableWizardBeanContext.java:21)
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, NPE: java.lang.NullPointerExcep
tion
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Path Settings ...
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Running Command - C:\DOCUME~1\I
ZAVIALO\LOCALS~1\Temp\forte61220.bat
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Path - C:\WINDOWS\syst
em32
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\WINDOWS
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking: C:\WINDOWS\jre
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Path - C:\WINDOWS
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Path - C:\WINDOWS\Syst
em32\Wbem
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.JDKSearchAction, dbg, Checking Path - "C:\Program Fil
es\Symantec\Norton Ghost 2003\"
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.installshield.wizard.RunnableWizardBeanContext, err, java.util.NoSu
chElementException
java.util.NoSuchElementException
        at java.util.Vector.firstElement(Unknown Source)
        at
com.sun.installer.JDKSearchAction.setLatestVersionIndex(JDKSearchAction.java:386)
        at
com.sun.installer.JDKSearchAction.execute(JDKSearchAction.java:83)
        at
com.installshield.wizard.RunnableWizardBeanContext.run(RunnableWizardBeanContext.java:21)
(Feb 8, 2004 3:54:52 PM), Setup.product.install,
com.sun.installer.SystemPropertyWizardBeanCondition, dbg, Condition for
 continueInstallation : (true,true) -> true
(Feb 8, 2004 3:55:17 PM), Setup.product.install,
com.sun.installer.JDKSelectionPanel, dbg, Checking: C:\Program Files\Su
n\j2sdk1.4.2
(Feb 8, 2004 3:55:17 PM), Setup.product.install,
com.sun.installer.JDKSelectionPanel, dbg, Checking: C:\Program Files\Su
n\j2sdk1.4.2\jre
(Feb 8, 2004 3:55:17 PM), Setup.product.install,
com.sun.installer.JDKSelectionPanel, dbg, Exists: C:\Program Files\Sun\
j2sdk1.4.2\jre
CreateProcess: C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe -version
error=193
java.io.IOException: CreateProcess: C:\Program
Files\Sun\j2sdk1.4.2\bin\java.exe -version error=193
        at java.lang.Win32Process.create(Native Method)
        at java.lang.Win32Process.<init>(Unknown Source)
        at java.lang.Runtime.execInternal(Native Method)
        at java.lang.Runtime.exec(Unknown Source)
        at java.lang.Runtime.exec(Unknown Source)
        at com.sun.installer.RunCommand.execute(RunCommand.java:56)
        at com.sun.installer.RunCommand.execute(RunCommand.java:47)
        at
com.sun.installer.JDKSearchAction.getJVMInfo(JDKSearchAction.java:302)
        at
com.sun.installer.JDKSearchAction.checkJdkHome(JDKSearchAction.java:264)
        at
com.sun.installer.JDKSelectionPanel.checkJDK(JDKSelectionPanel.java:263)
        at
com.sun.installer.JDKSelectionPanel.queryExit(JDKSelectionPanel.java:219)
        at
com.installshield.wizard.awt.AWTWizardUI.doNext(AWTWizardUI.java:1200)
        at
com.installshield.wizard.awt.AWTWizardUI.actionPerformed(AWTWizardUI.java:1077)
        at
com.installshield.wizard.swing.SwingWizardUI.actionPerformed(SwingWizardUI.java:736)
        at
com.installshield.wizard.swing.SwingWizardUI$SwingNavigationController.notifyListeners(SwingWizardUI.java:866
)
        at
com.installshield.wizard.swing.SwingWizardUI$SwingNavigationController.actionPerformed(SwingWizardUI.java:860
)
        at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
        at
javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Unknown
Source)
        at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown
Source)
        at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
        at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
        at java.awt.Component.processMouseEvent(Unknown Source)
        at java.awt.Component.processEvent(Unknown Source)
        at java.awt.Container.processEvent(Unknown Source)
        at java.awt.Component.dispatchEventImpl(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown
Source)
        at java.awt.LightweightDispatcher.processMouseEvent(Unknown
Source)
        at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
        at java.awt.Container.dispatchEventImpl(Unknown Source)
        at java.awt.Window.dispatchEventImpl(Unknown Source)
        at java.awt.Component.dispatchEvent(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown
Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
(Feb 8, 2004 3:55:17 PM), Setup.product.install,
com.sun.installer.JDKSelectionPanel, dbg, NPE: java.lang.NullPointerExc
eption

Wizard.getExitCode(): called after WizardServices is shutdown.
Wizard.getExitCode(): called after WizardServices is shutdown.
Comment 4 George Hernandez 2004-02-08 21:23:26 UTC
Is it possiblem your jvm is corrupted? If you run the command from the
command prompt window, what do you get:

C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe -version
Comment 5 oneway 2004-02-08 23:41:20 UTC
I'd say it's unlikely.

C:\>C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe -version
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.

C:\>"C:\Program Files\Sun\j2sdk1.4.2\bin\java.exe" -version
java version "1.4.2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-b28)
Java HotSpot(TM) Client VM (build 1.4.2-b28, mixed mode)

C:\>"C:\Progra~1\Sun\j2sdk1.4.2\bin\java.exe" -version
java version "1.4.2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-b28)
Java HotSpot(TM) Client VM (build 1.4.2-b28, mixed mode)

Comment 6 Patrick Keegan 2004-03-03 21:24:10 UTC
Any ideas for release note text? Is this a case of the installer not
finding a JDK beta?
Comment 7 George Hernandez 2004-03-03 21:40:29 UTC
This is a case of the command being executed on the system failing. I
can't reproduce this. I suspect there is some subtle problem in the
RunCommand class.
Comment 8 mslama 2005-02-11 11:04:23 UTC
This might be problem with space in JDK path. JDK 1.4.X has default
install dir c:\j2sdk... not "C:\Program Files\Java\j2sdk...." This was
changed for JDK 5.0 to standard default installation location. I will
test it on Win XP.
Comment 9 mslama 2005-03-21 11:53:45 UTC
I just tried on Win XP. Current installer daily dev build works even if JDK
1.4.2_07 is installed in path with space like "C:\Program
Files\Java\j2sdk1.4.2_07". I tested with
netbeans-4_1-daily-bin-200503201900-windows-20_Mar_2005_1900.exe