You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by ANKUR GOEL <an...@corp.aol.com> on 2007/12/14 13:16:05 UTC

Unable to build hadoop on local machine

Hi,
      I have setup Hadoop in Eclipse 3.3 on my RedHat Linux, Kernel  
2.6.9-42.ELsmp
as per the instructions given on the Wiki page 
http://wiki.apache.org/lucene-hadoop/EclipseEnvironment.
I have included "contrib" directory in the source path and have ensured 
that all libraries are included
as per the instructions.

I am facing compilation issues with "hadoop/src/test" directory. 
Specifically files in
hadoop/src/test/org/apache/hadoop/record
don't seem to compile due to a missing class - RecRecord1.

Also after adding a new Ant builder and setting up targets as mentioned 
on the instructions page, the build seem
to fail after 47 min due to junit test failure. Here is a snapshot from 
the logs

*test:
        [echo] contrib: hbase
      [delete] Deleting directory 
/ankur-workspace/Eclipse/workspace/Hadoop/build/contrib/hbase/test/logs
       [mkdir] Created dir: 
/ankur-workspace/Eclipse/workspace/Hadoop/build/contrib/hbase/test/logs
       [junit] Running org.apache.hadoop.hbase.TestBatchUpdate
       [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 
74.358 sec
       ...
       [junit] Test org.apache.hadoop.hbase.mapred.TestTableMapReduce FAILED
*
Can anyone help me out in resolving these issues ?
Also, does it take so long to run all the unit tests and build hadoop ?


Thanks
-Ankur

RE: Unable to build hadoop on local machine

Posted by "Goel, Ankur" <An...@corp.aol.com>.
That's right as I did not see the attachments mentioned earlier.
However, removing 
	src/test/org/apache/hadoop/record 
directory from the build path fixes the compilation and build issue.

Also I was able to generate the packaged .tar file adding the top 
level Hadoop build.xml in the eclipse Ant view and executing the 
"tar" target.

Thanks
-Ankur 

-----Original Message-----
From: Doug Cutting [mailto:cutting@apache.org] 
Sent: Monday, December 17, 2007 11:51 PM
To: hadoop-dev@lucene.apache.org
Subject: Re: Unable to build hadoop on local machine

Nigel Daley wrote:
> IIRC, attachments are auto removed on this list.

No, but they are removed by lots of mail servers, so they frequently
don't seem to survive when folks post them to this list and hence cannot
be recommended.

Doug

Re: Unable to build hadoop on local machine

Posted by Doug Cutting <cu...@apache.org>.
Nigel Daley wrote:
> IIRC, attachments are auto removed on this list.

No, but they are removed by lots of mail servers, so they frequently 
don't seem to survive when folks post them to this list and hence cannot 
be recommended.

Doug

Re: Unable to build hadoop on local machine

Posted by Nigel Daley <nd...@yahoo-inc.com>.
>> I have attached a tar file of the .project, .classpath  
>> and .externalToolBuilder

IIRC, attachments are auto removed on this list.

Nige


Re: Unable to build hadoop on local machine

Posted by Sanjay Radia <sr...@yahoo-inc.com>.
ANKUR GOEL wrote:
> Hi,
>      I have setup Hadoop in Eclipse 3.3 on my RedHat Linux, Kernel  
> 2.6.9-42.ELsmp
> as per the instructions given on the Wiki page 
> http://wiki.apache.org/lucene-hadoop/EclipseEnvironment.
> I have included "contrib" directory in the source path and have 
> ensured that all libraries are included
> as per the instructions.
>
> I am facing compilation issues with "hadoop/src/test" directory. 
> Specifically files in
> hadoop/src/test/org/apache/hadoop/record
> don't seem to compile due to a missing class - RecRecord1.
>
> Also after adding a new Ant builder and setting up targets as 
> mentioned on the instructions page, the build seem
> to fail after 47 min due to junit test failure. Here is a snapshot 
> from the logs
>
> *test:
>        [echo] contrib: hbase
>      [delete] Deleting directory 
> /ankur-workspace/Eclipse/workspace/Hadoop/build/contrib/hbase/test/logs
>       [mkdir] Created dir: 
> /ankur-workspace/Eclipse/workspace/Hadoop/build/contrib/hbase/test/logs
>       [junit] Running org.apache.hadoop.hbase.TestBatchUpdate
>       [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 
> 74.358 sec
>       ...
>       [junit] Test org.apache.hadoop.hbase.mapred.TestTableMapReduce 
> FAILED
> *
> Can anyone help me out in resolving these issues ?
> Also, does it take so long to run all the unit tests and build hadoop ?
>
>
> Thanks
> -Ankur
>
I have attached a tar file of the .project, .classpath and 
.externalToolBuilder
Copy these to the project root directory and change the 
"PROJECT_NAMExxx" (I might have the actual spelling wrong)
with your project name and all should be fine.
For your particular problem just copying the .classpass from the tar may 
also be good enough.

IF you wish to change things manually in your project you need to 
exclude the following from the
source
  from src/test exclude:
      org/apache/hadoop/record

 from src/java exclude:
  or/apache/hadoop/record/ant

I routinely create projects using the tar file and replacing the 
PROJECT_NAME.

good luck.


sanjay