You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by "Johannes Bauer (JIRA)" <ji...@apache.org> on 2014/11/04 13:36:34 UTC

[jira] [Updated] (ACCUMULO-3293) bin\winutils.exe not found when running MiniAccumuloCluster under Windows

     [ https://issues.apache.org/jira/browse/ACCUMULO-3293?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Johannes Bauer updated ACCUMULO-3293:
-------------------------------------
    Description: 
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 
{{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)}}
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 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 310:

{{    builder.environment().put("HADOOP_HOME", config.getDir().getAbsolutePath());}}

with the following lines: 

{{	env = System.getProperty("hadoop.home.dir");}}
{{	if(env == null) }}
{{	  env = System.getenv("HADOOP_HOME");}}
{{	if(env == null)}}
{{	  env = config.getDir().getAbsolutePath();}}
{{    builder.environment().put("HADOOP_HOME", env);}}

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!


  was:
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 AccumuloMiniCluster 1.4.4.

When I try the same with Accumulo 1.6, I get the error 
{{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)}}
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 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 310:

{{    builder.environment().put("HADOOP_HOME", config.getDir().getAbsolutePath());}}

with the following lines: 

{{	env = System.getProperty("hadoop.home.dir");}}
{{	if(env == null) }}
{{	  env = System.getenv("HADOOP_HOME");}}
{{	if(env == null)}}
{{	  env = config.getDir().getAbsolutePath();}}
{{    builder.environment().put("HADOOP_HOME", env);}}

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!



> 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 
> {{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)}}
> 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 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 310:
> {{    builder.environment().put("HADOOP_HOME", config.getDir().getAbsolutePath());}}
> with the following lines: 
> {{	env = System.getProperty("hadoop.home.dir");}}
> {{	if(env == null) }}
> {{	  env = System.getenv("HADOOP_HOME");}}
> {{	if(env == null)}}
> {{	  env = config.getDir().getAbsolutePath();}}
> {{    builder.environment().put("HADOOP_HOME", env);}}
> 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)