You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by Mohit Anchlia <mo...@gmail.com> on 2012/08/03 06:01:21 UTC

HBaseTestingUtility on windows

I am trying to run mini cluster using HBaseTestingUtility Class from hbase
tests on windows, but I get "bash command error". Is it not possible to run
this utility class on windows?

I followed this example:

http://blog.sematext.com/2010/08/30/hbase-case-study-using-hbasetestingutility-for-local-testing-development/

Re: HBaseTestingUtility on windows

Posted by Shrijeet Paliwal <sh...@rocketfuel.com>.
https://issues.apache.org/jira/browse/HDFS-197 has a workaround (see
last comment)

On Fri, Aug 3, 2012 at 1:33 PM, Mohit Anchlia <mo...@gmail.com> wrote:
> I ran test from cygwin but it fails here. Could someone help me with how to
> go about fixing this issue?
>
> java.io.IOException: Expecting a line not the end of stream
> at org.apache.hadoop.fs.DF.parseExecResult(DF.java:117)
> at org.apache.hadoop.util.Shell.runCommand(Shell.java:237)
> at org.apache.hadoop.util.Shell.run(Shell.java:182)
> at org.apache.hadoop.fs.DF.getFilesystem(DF.java:63)
> at
> org.apache.hadoop.hdfs.server.namenode.NameNodeResourceChecker.addDirsToCheck(NameNodeResourceChecker.java:93)
> at
> org.apache.hadoop.hdfs.server.namenode.NameNodeResourceChecker.<init>(NameNodeResourceChecker.java:73)
> at
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.initialize(FSNamesystem.java:354)
> at
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.<init>(FSNamesystem.java:333)
> at
> org.apache.hadoop.hdfs.server.namenode.NameNode.initialize(NameNode.java:271)
> at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:465)
> at
> org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1251)
> at org.apache.hadoop.hdfs.MiniDFSCluster.<init>(MiniDFSCluster.java:278)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniDFSCluster(HBaseTestingUtility.java:226)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:348)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:293)
> at
> com.intuit.cg.services.dp.analytics.hbase.SessionTimelineDAOTest.initCluster(SessionTimelineDAOTest.java:44)
> at
> org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:61)
> at
> org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeMulti(TestNGDirectoryTestSuite.java:163)
> at
> org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:112)
> at
> org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:111)
> at
> org.apache.maven.surefire.booter.ProviderFactory$ClassLoaderProxy.invoke(ProviderFactory.java:103)
> at $Proxy0.invoke(Unknown Source)
> at
> org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:145)
> at
> org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcess(SurefireStarter.java:87)
> at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:69)
>
>
> On Fri, Aug 3, 2012 at 11:44 AM, Jerry Lam <ch...@gmail.com> wrote:
>
>> Hi Mohit:
>>
>> You might need to install Cygwin if the tool has dependency on Linux
>> command like bash.
>>
>> Best Regards,
>>
>> Jerry
>>
>> On Friday, August 3, 2012, N Keywal wrote:
>>
>> > Hi Mohit,
>> >
>> > For simple cases, it works for me for hbase 0.94 at least. But I'm not
>> > sure it works for all features. I've never tried to run hbase unit
>> > tests on windows for example.
>> >
>> > N.
>> >
>> > On Fri, Aug 3, 2012 at 6:01 AM, Mohit Anchlia <mohitanchlia@gmail.com
>> <javascript:;>>
>>  > wrote:
>> > > I am trying to run mini cluster using HBaseTestingUtility Class from
>> > hbase
>> > > tests on windows, but I get "bash command error". Is it not possible to
>> > run
>> > > this utility class on windows?
>> > >
>> > > I followed this example:
>> > >
>> > >
>> >
>> http://blog.sematext.com/2010/08/30/hbase-case-study-using-hbasetestingutility-for-local-testing-development/
>> >
>>

Re: HBaseTestingUtility on windows

Posted by Mohit Anchlia <mo...@gmail.com>.
I ran test from cygwin but it fails here. Could someone help me with how to
go about fixing this issue?

java.io.IOException: Expecting a line not the end of stream
at org.apache.hadoop.fs.DF.parseExecResult(DF.java:117)
at org.apache.hadoop.util.Shell.runCommand(Shell.java:237)
at org.apache.hadoop.util.Shell.run(Shell.java:182)
at org.apache.hadoop.fs.DF.getFilesystem(DF.java:63)
at
org.apache.hadoop.hdfs.server.namenode.NameNodeResourceChecker.addDirsToCheck(NameNodeResourceChecker.java:93)
at
org.apache.hadoop.hdfs.server.namenode.NameNodeResourceChecker.<init>(NameNodeResourceChecker.java:73)
at
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.initialize(FSNamesystem.java:354)
at
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.<init>(FSNamesystem.java:333)
at
org.apache.hadoop.hdfs.server.namenode.NameNode.initialize(NameNode.java:271)
at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:465)
at
org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1251)
at org.apache.hadoop.hdfs.MiniDFSCluster.<init>(MiniDFSCluster.java:278)
at
org.apache.hadoop.hbase.HBaseTestingUtility.startMiniDFSCluster(HBaseTestingUtility.java:226)
at
org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:348)
at
org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:293)
at
com.intuit.cg.services.dp.analytics.hbase.SessionTimelineDAOTest.initCluster(SessionTimelineDAOTest.java:44)
at
org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:61)
at
org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeMulti(TestNGDirectoryTestSuite.java:163)
at
org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:112)
at
org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:111)
at
org.apache.maven.surefire.booter.ProviderFactory$ClassLoaderProxy.invoke(ProviderFactory.java:103)
at $Proxy0.invoke(Unknown Source)
at
org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:145)
at
org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcess(SurefireStarter.java:87)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:69)


On Fri, Aug 3, 2012 at 11:44 AM, Jerry Lam <ch...@gmail.com> wrote:

> Hi Mohit:
>
> You might need to install Cygwin if the tool has dependency on Linux
> command like bash.
>
> Best Regards,
>
> Jerry
>
> On Friday, August 3, 2012, N Keywal wrote:
>
> > Hi Mohit,
> >
> > For simple cases, it works for me for hbase 0.94 at least. But I'm not
> > sure it works for all features. I've never tried to run hbase unit
> > tests on windows for example.
> >
> > N.
> >
> > On Fri, Aug 3, 2012 at 6:01 AM, Mohit Anchlia <mohitanchlia@gmail.com
> <javascript:;>>
>  > wrote:
> > > I am trying to run mini cluster using HBaseTestingUtility Class from
> > hbase
> > > tests on windows, but I get "bash command error". Is it not possible to
> > run
> > > this utility class on windows?
> > >
> > > I followed this example:
> > >
> > >
> >
> http://blog.sematext.com/2010/08/30/hbase-case-study-using-hbasetestingutility-for-local-testing-development/
> >
>

Re: HBaseTestingUtility on windows

Posted by Jerry Lam <ch...@gmail.com>.
Hi Mohit:

You might need to install Cygwin if the tool has dependency on Linux
command like bash.

Best Regards,

Jerry

On Friday, August 3, 2012, N Keywal wrote:

> Hi Mohit,
>
> For simple cases, it works for me for hbase 0.94 at least. But I'm not
> sure it works for all features. I've never tried to run hbase unit
> tests on windows for example.
>
> N.
>
> On Fri, Aug 3, 2012 at 6:01 AM, Mohit Anchlia <mohitanchlia@gmail.com<javascript:;>>
> wrote:
> > I am trying to run mini cluster using HBaseTestingUtility Class from
> hbase
> > tests on windows, but I get "bash command error". Is it not possible to
> run
> > this utility class on windows?
> >
> > I followed this example:
> >
> >
> http://blog.sematext.com/2010/08/30/hbase-case-study-using-hbasetestingutility-for-local-testing-development/
>

Re: HBaseTestingUtility on windows

Posted by N Keywal <nk...@gmail.com>.
Hi Mohit,

For simple cases, it works for me for hbase 0.94 at least. But I'm not
sure it works for all features. I've never tried to run hbase unit
tests on windows for example.

N.

On Fri, Aug 3, 2012 at 6:01 AM, Mohit Anchlia <mo...@gmail.com> wrote:
> I am trying to run mini cluster using HBaseTestingUtility Class from hbase
> tests on windows, but I get "bash command error". Is it not possible to run
> this utility class on windows?
>
> I followed this example:
>
> http://blog.sematext.com/2010/08/30/hbase-case-study-using-hbasetestingutility-for-local-testing-development/