accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Johannes Bauer (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ACCUMULO-3293) bin\winutils.exe not found when running MiniAccumuloCluster under Windows
Date Fri, 07 Nov 2014 12:16:33 GMT

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

Johannes Bauer commented on ACCUMULO-3293:
------------------------------------------

Hello Josh,
thanks for your fast answer. Meanwhile, we switched from Hadoop 2.2.0cdh5.0.0-beta-2 to 2.5.0cdh5.2.0.
Now the problem does not occur any more, even though I still put some time in the issue to
reproduce it. Because of that I'll resolve the issue. There are other problems, which I'll
describe in other tickets, though. 

To run JUnit-Tests with the AccumuloMiniCluster on Windows, one needs winutils.exe, which
is searched in the Path in {{HADOOP_HOME}}:
http://stackoverflow.com/questions/18630019/running-apache-hadoop-2-1-0-on-windows

Before our switch to Hadoop 2.5 somehow the Hadoop Shell was called by the code, mentioned
above in a new process, and so {{HADOOP_HOME}} was wrong. Now it's called just directly, not
in a own process any more, so the {{HADOOP_HOME}} variable is correct, and {{winutils.exe}}
is found. If {{winutils.exe}} is not there, you cannot run the MiniAccumuloCluster on Windows,
that's still the same. I checked it by renaming the file. 
I still think, that the code I wrote above would be more correct, as it would pass the right
{{HADOOP_HOME}} to the newly created process, but right now, the problem does not occur on
our system any more. 

Thanks for your help and sorry for the inconvenience! Johannes

> bin\winutils.exe not found when running MiniAccumuloCluster under Windows
> -------------------------------------------------------------------------
>
>                 Key: ACCUMULO-3293
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-3293
>             Project: Accumulo
>          Issue Type: Bug
>          Components: mini
>         Environment: MS Windows
>            Reporter: Johannes Bauer
>
> When running JUnit-Tests on Windows with the MiniAccumuloCluster, the file {{bin\winutils.exe}}
is needed, which is searched in the path, given by the system variable {{HADOOP_HOME}}. This
worked fine with the MiniAccumuloCluster 1.4.4.
> When I try the same with Accumulo 1.6, I get the error 
> {code}
> 14/10/24 16:57:40 ERROR util.Shell: Failed to locate the winutils binary in the hadoop
binary path
> java.io.IOException: Could not locate executable C:\Users\jsbaue\AppData\Local\Temp\1414162594270-0\bin\winutils.exe
in the Hadoop binaries.
> 	at org.apache.hadoop.util.Shell.getQualifiedBinPath(Shell.java:318)
> 	at org.apache.hadoop.util.Shell.getWinUtilsPath(Shell.java:333)
> 	at org.apache.hadoop.util.Shell.<clinit>(Shell.java:326)
> 	at org.apache.hadoop.util.StringUtils.<clinit>(StringUtils.java:76)
> {code}
> which basically says, that {{bin\winutils.exe}} is now searched in the temporary path,
given to the MiniAccumuloCluster. When I try to put the file {{bin\winutils.exe}} in that
path, I get an error, saying that the path has to be empty. 
> I fixed this problem by changing {{accumulo\minicluster\src\main\java\org\apache\accumulo\minicluster\impl\MiniAccumuloClusterImpl.java}}:
> I exchanged Line 309-310:
> {code}
>     // hadoop-2.2 puts error messages in the logs if this is not set
>     builder.environment().put("HADOOP_HOME", config.getDir().getAbsolutePath());
> {code}
> with the following lines: 
> {code}
>     env = System.getProperty("hadoop.home.dir");
>     if(env == null) 
>         env = System.getenv("HADOOP_HOME");
>     // hadoop-2.2 puts error messages in the logs if this is not set
>     if(env == null)
>         env = config.getDir().getAbsolutePath();
>     builder.environment().put("HADOOP_HOME", env);
> {code}
> This fixes the bug on Windows. I did no checks on Linux. 
> Could you check, if you chould change this in the next version of the MiniAccumuloCluster
or help me with an other solution? Thanks!



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message