karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Raphael Majeed (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KARAF-1799) JAVA_HOME autodiscovery not working on Windows 7 (karaf.bat)
Date Fri, 07 Sep 2012 13:09:08 GMT

    [ https://issues.apache.org/jira/browse/KARAF-1799?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13450599#comment-13450599
] 

Raphael Majeed commented on KARAF-1799:
---------------------------------------

Better solution for JAVA_HOME autodiscovery: use "REG QUERY ..." (available since WinXP)
e.g. try running
{code}
REG QUERY "HKLM\Software\JavaSoft\Java Runtime Environment" /v CurrentVersion
REG QUERY "HKLM\Software\JavaSoft\Java Runtime Environment\1.6" /v JavaHome
{code}
in the console.

See also http://www.chriskopec.com/blog/2009/jun/15/automatic-discovery-java_home-batch-file/

                
> JAVA_HOME autodiscovery not working on Windows 7 (karaf.bat)
> ------------------------------------------------------------
>
>                 Key: KARAF-1799
>                 URL: https://issues.apache.org/jira/browse/KARAF-1799
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-os-integration
>    Affects Versions: 2.2.9
>         Environment: Windows 7 Professional, JDK 1.6.0_35, JDK 1.7.0_07, jre6, jre7
>            Reporter: Raphael Majeed
>
> When running karaf.bat without setting JAVA_HOME, karaf.bat tries to determine JAVA_HOME
automatically.
> The following happens on Windows 7:
> 1. The built in windows security manager asks for permission to allow regedit to access
the registry twice.
> 2. karaf.bat exits with message "Unable to retrieve JAVA_HOME"

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message