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

Eli Collins commented on HADOOP-6605:
-------------------------------------

Thanks for the feedback Daryn.  It looks like /usr/libexec/java_home is the 
right method for newer Mac systems as the paths it returns is not very generic 
(in the way the others are), eg has particular dot version numbers in the name. 
How about, if /usr/libexec/java_home is present, the path it returns is put in 
the list before /Library/Java/Home? This should work for both older and newer 
versions of OS X. I could remove /Library/Java/Home from the current version of 
the patch and we could do that as a change that applies atop this one (I don't 
have a Mac) or I could make this change as part of this patch and you could try 
it for me?

(As an aside, I'm surprised -1s are coming out on rev 1 of a patch, we normally 
we go back and forth on the review before veto'ing a patch, ie if there are 
technical objections that are not addressed in subsequent versions. I will try 
to address any technical objections raised).

> Add JAVA_HOME detection to hadoop-config
> ----------------------------------------
>
>                 Key: HADOOP-6605
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6605
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Chad Metcalf
>            Assignee: Eli Collins
>            Priority: Minor
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6605.patch, hadoop-6605-1.patch
>
>
> The commands that source hadoop-config.sh currently bail with an error if 
> JAVA_HOME is not set. Let's detect JAVA_HOME (from a list of locations on 
> various OS types) if JAVA_HOME is not already set by hadoop-env.sh or the 
> environment. This way users don't have to manually configure it.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to