You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by Massoud Mazar <Ma...@avg.com> on 2009/11/06 16:15:50 UTC

Problem installing Hive on hadoop 0.20.1

Hi,

I have a 2 node hadoop/hbase cluster which is working fine. 
hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)

I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted.
When I try to run hive CLI, I get the following error:

hadoop@hadoop-1:/usr/local/hive$ bin/hive
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/hadoop/hive/conf/HiveConf
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:247)
        at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hive.conf.HiveConf
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
        ... 3 more

Any help is greatly appreciated.
Massoud

Re: ArrayIndexOutOfBoundsException during getTaskInProgress

Posted by Ryan LeCompte <le...@gmail.com>.
Also, one more thing... Don't build from trunk as the getting started guide
suggests. You want to SVN co the following:

svn co http://svn.apache.org/repos/asf/hadoop/hive/tags/release-0.4.1-rc2/



On Mon, Nov 9, 2009 at 3:30 PM, Ryan LeCompte <le...@gmail.com> wrote:

> Hi Massoud,
>
> Couple things you could do:
>
> 1) Log into the Job Tracker console and click on the failed map/reduce
> tasks to view the logs. Check for any exceptions there.
> -- go to http://master:50030/jobdetails.jsp?jobid=job_200911091418_0004
>
> 2) Check the Hive logs, which are configured by
> build/dist/conf/hive-log4j.properties.
> -- you can change the location of where the logs go by modifying
> "hive.log.dir"
>
> Thanks,
> Ryan
>
>
> On Mon, Nov 9, 2009 at 3:25 PM, Massoud Mazar <Ma...@avg.com>wrote:
>
>> I thought I got my hive installation right, but apparently I was wrong.
>> When I follow instruction on creating and populating and querying
>> "MovieLens User Ratings" from Hive User Guide (
>> http://wiki.apache.org/hadoop/Hive/UserGuide) I get the following error:
>>
>> hive> SELECT COUNT(1) FROM u_data;
>> Total MapReduce jobs = 1
>> Number of reduce tasks determined at compile time: 1
>> In order to change the average load for a reducer (in bytes):
>>  set hive.exec.reducers.bytes.per.reducer=<number>
>> In order to limit the maximum number of reducers:
>>  set hive.exec.reducers.max=<number>
>> In order to set a constant number of reducers:
>>  set mapred.reduce.tasks=<number>
>> Starting Job = job_200911091418_0004, Tracking URL =
>> http://master:50030/jobdetails.jsp?jobid=job_200911091418_0004
>> Kill Command = /usr/local/hadoop/bin/hadoop job
>>  -Dmapred.job.tracker=master:9001 -kill job_200911091418_0004
>> 2009-11-09 03:06:02,651 map = 100%,  reduce = 100%
>> Ended Job = job_200911091418_0004 with errors
>> FAILED: Execution Error, return code 2 from
>> org.apache.hadoop.hive.ql.exec.ExecDriver
>>
>> Any advise on how to troubleshoot this is very much appreciated.
>>
>> Regards
>> Massoud
>>
>
>

RE: Problem installing Hive on hadoop 0.20.1

Posted by Massoud Mazar <Ma...@avg.com>.
Thanks Zheng.
You are right, I was messing up the HADOOP_CLASSPATH and your suggestion fixed the issue.

From: Zheng Shao [mailto:zshao9@gmail.com]
Sent: Monday, November 09, 2009 6:21 PM
To: hive-user@hadoop.apache.org
Subject: Re: Problem installing Hive on hadoop 0.20.1

Hi Massoud,

This is not expected.

Are you setting HADOOP_CLASSPATH in hadoop-env.sh?
If you set it, I think it should be "HADOOP_CLASSPATH=${HADOOP_CLASSPATH}:additional_path" so that it does not erase existing HADOOP_CLASSPATH set by Hive.

Can you post your hadoop-env.sh?

Zheng
On Mon, Nov 9, 2009 at 8:34 AM, Massoud Mazar <Ma...@avg.com>> wrote:
Just wanted to thank everyone who provided guidance to help me with my hive issue. In case others have the same problem, it was a HADOOP_CLASSPATH issue.

I cleaned up everything hive related and started from scratch.
(I did the following on master node of my 2 node hadoop 0.20.1 cluster, running on ubuntu 9.04)

$ svn co http://svn.apache.org/repos/asf/hadoop/hive/trunk hive
$ cd hive
$ ant -Dhadoop.version="0.20.0" package
$ ant test -Dtestcase=TestCliDriver -Dqfile=create_1.q
BUILD SUCCESSFUL
$ cd build/dist
$ bin/hive
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/hadoop/hive/conf/HiveConf
       at java.lang.Class.forName0(Native Method)
       at java.lang.Class.forName(Class.java:247)
       at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hive.conf.HiveConf
       at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
       at java.security.AccessController.doPrivileged(Native Method)
       at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
       ... 3 more
What fixed my problem was to edit hadoop-env.sh and add most of the jars in hive/lib to the end of HADOOP_CLASSPATH.
Then I was able to run bin/hive.

Thanks all.
Massoud Mazar



--
Yours,
Zheng

Re: Problem installing Hive on hadoop 0.20.1

Posted by Zheng Shao <zs...@gmail.com>.
Hi Massoud,

This is not expected.

Are you setting HADOOP_CLASSPATH in hadoop-env.sh?
If you set it, I think it should be
"HADOOP_CLASSPATH=${HADOOP_CLASSPATH}:additional_path" so that it does not
erase existing HADOOP_CLASSPATH set by Hive.

Can you post your hadoop-env.sh?

Zheng

On Mon, Nov 9, 2009 at 8:34 AM, Massoud Mazar <Ma...@avg.com> wrote:

> Just wanted to thank everyone who provided guidance to help me with my hive
> issue. In case others have the same problem, it was a HADOOP_CLASSPATH
> issue.
>
> I cleaned up everything hive related and started from scratch.
> (I did the following on master node of my 2 node hadoop 0.20.1 cluster,
> running on ubuntu 9.04)
>
> $ svn co http://svn.apache.org/repos/asf/hadoop/hive/trunk hive
> $ cd hive
> $ ant -Dhadoop.version="0.20.0" package
> $ ant test -Dtestcase=TestCliDriver -Dqfile=create_1.q
> BUILD SUCCESSFUL
> $ cd build/dist
> $ bin/hive
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/hadoop/hive/conf/HiveConf
>        at java.lang.Class.forName0(Native Method)
>        at java.lang.Class.forName(Class.java:247)
>        at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
> Caused by: java.lang.ClassNotFoundException:
> org.apache.hadoop.hive.conf.HiveConf
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>        ... 3 more
>
> What fixed my problem was to edit hadoop-env.sh and add most of the jars in
> hive/lib to the end of HADOOP_CLASSPATH.
> Then I was able to run bin/hive.
>
> Thanks all.
> Massoud Mazar
>



-- 
Yours,
Zheng

RE: Problem installing Hive on hadoop 0.20.1

Posted by Massoud Mazar <Ma...@avg.com>.
Just wanted to thank everyone who provided guidance to help me with my hive issue. In case others have the same problem, it was a HADOOP_CLASSPATH issue.

I cleaned up everything hive related and started from scratch.
(I did the following on master node of my 2 node hadoop 0.20.1 cluster, running on ubuntu 9.04)

$ svn co http://svn.apache.org/repos/asf/hadoop/hive/trunk hive
$ cd hive
$ ant -Dhadoop.version="0.20.0" package
$ ant test -Dtestcase=TestCliDriver -Dqfile=create_1.q
BUILD SUCCESSFUL
$ cd build/dist
$ bin/hive
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/hadoop/hive/conf/HiveConf
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:247)
        at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hive.conf.HiveConf
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
        ... 3 more

What fixed my problem was to edit hadoop-env.sh and add most of the jars in hive/lib to the end of HADOOP_CLASSPATH.
Then I was able to run bin/hive.

Thanks all.
Massoud Mazar

Re: ArrayIndexOutOfBoundsException during getTaskInProgress

Posted by Ryan LeCompte <le...@gmail.com>.
Hi Massoud,

Couple things you could do:

1) Log into the Job Tracker console and click on the failed map/reduce tasks
to view the logs. Check for any exceptions there.
-- go to http://master:50030/jobdetails.jsp?jobid=job_200911091418_0004

2) Check the Hive logs, which are configured by
build/dist/conf/hive-log4j.properties.
-- you can change the location of where the logs go by modifying
"hive.log.dir"

Thanks,
Ryan

On Mon, Nov 9, 2009 at 3:25 PM, Massoud Mazar <Ma...@avg.com> wrote:

> I thought I got my hive installation right, but apparently I was wrong.
> When I follow instruction on creating and populating and querying
> "MovieLens User Ratings" from Hive User Guide (
> http://wiki.apache.org/hadoop/Hive/UserGuide) I get the following error:
>
> hive> SELECT COUNT(1) FROM u_data;
> Total MapReduce jobs = 1
> Number of reduce tasks determined at compile time: 1
> In order to change the average load for a reducer (in bytes):
>  set hive.exec.reducers.bytes.per.reducer=<number>
> In order to limit the maximum number of reducers:
>  set hive.exec.reducers.max=<number>
> In order to set a constant number of reducers:
>  set mapred.reduce.tasks=<number>
> Starting Job = job_200911091418_0004, Tracking URL =
> http://master:50030/jobdetails.jsp?jobid=job_200911091418_0004
> Kill Command = /usr/local/hadoop/bin/hadoop job
>  -Dmapred.job.tracker=master:9001 -kill job_200911091418_0004
> 2009-11-09 03:06:02,651 map = 100%,  reduce = 100%
> Ended Job = job_200911091418_0004 with errors
> FAILED: Execution Error, return code 2 from
> org.apache.hadoop.hive.ql.exec.ExecDriver
>
> Any advise on how to troubleshoot this is very much appreciated.
>
> Regards
> Massoud
>

ArrayIndexOutOfBoundsException during getTaskInProgress

Posted by Massoud Mazar <Ma...@avg.com>.
I thought I got my hive installation right, but apparently I was wrong.
When I follow instruction on creating and populating and querying "MovieLens User Ratings" from Hive User Guide (http://wiki.apache.org/hadoop/Hive/UserGuide) I get the following error:

hive> SELECT COUNT(1) FROM u_data;
Total MapReduce jobs = 1
Number of reduce tasks determined at compile time: 1
In order to change the average load for a reducer (in bytes):
  set hive.exec.reducers.bytes.per.reducer=<number>
In order to limit the maximum number of reducers:
  set hive.exec.reducers.max=<number>
In order to set a constant number of reducers:
  set mapred.reduce.tasks=<number>
Starting Job = job_200911091418_0004, Tracking URL = http://master:50030/jobdetails.jsp?jobid=job_200911091418_0004
Kill Command = /usr/local/hadoop/bin/hadoop job  -Dmapred.job.tracker=master:9001 -kill job_200911091418_0004
2009-11-09 03:06:02,651 map = 100%,  reduce = 100%
Ended Job = job_200911091418_0004 with errors
FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.ExecDriver

Any advise on how to troubleshoot this is very much appreciated.

Regards
Massoud

Re: Problem installing Hive on hadoop 0.20.1

Posted by Zheng Shao <zs...@gmail.com>.
Hi Massoud,

Once you did "ant package", you will need to go into "build/dist" and then
run "bin/hive"

Zheng

On Fri, Nov 6, 2009 at 11:27 AM, Ning Zhang <nz...@facebook.com> wrote:

> Sorry there was a typo in my previous email: please replace testcaes
> to testcase in the unit test command.  Basically if the unit tests do
> not pass, the hive distribution is not working. I suggest you check
> out a brand new trunk and try 'ant package' followed by ant test of
> one of the unit test qfile (e.g., create_1.q).
>
> If that still fails, please open a JIRA under hadoop/Hive and include
> all the info about the environment and steps you have done and also
> post the log file under your build/ql/tmp/hive.log after you have run
> the one unit test.
>
> Ning
>
> On Nov 6, 2009, at 11:13 AM, Massoud Mazar wrote:
>
> > I tried both trunk and /tags/release-0.4.0 (currently using 0.4.0)
> > $JAVA_HOME points to /usr/lib/jvm/java-6-sun
> > I'm using ubuntu server, so I guess it is bash
> >
> > ant test -Dtestcaes=TestCliDriver -Dqfile=create_1.q
> > says (at the end)
> >
> > BUILD FAILED
> > /tmp/hive/build.xml:142: The following error occurred while
> > executing this line:
> > /tmp/hive/build.xml:89: The following error occurred while executing
> > this line:
> > /tmp/hive/build-common.xml:316: Tests failed!
> >
> > -----Original Message-----
> > From: Ning Zhang [mailto:nzhang@facebook.com]
> > Sent: Friday, November 06, 2009 1:29 PM
> > To: hive-user@hadoop.apache.org
> > Subject: Re: Problem installing Hive on hadoop 0.20.1
> >
> > Are you using Hive trunk or branch-0.4? Which version of Java
> > $JAVA_HOME is pointing to? Which shell are you using (csh/bash...)?
> > Are you able to run some unit test under your "build directory" (the
> > directory which contains build/dist), say  ant test -
> > Dtestcaes=TestCliDriver -Dqfile=create_1.q
> >
> >  Ning
> >
> > On Nov 6, 2009, at 9:00 AM, Massoud Mazar wrote:
> >
> >> Tried all paths suggested, still get the same error. $CDPATH is
> >> empty and
> >>
> >> hadoop@hadoop-1:/usr/local/hive/bin$ echo $PATH
> >> /usr/local/bin:/usr/bin:/bin
> >>
> >> -----Original Message-----
> >> From: Ning Zhang [mailto:nzhang@facebook.com]
> >> Sent: Friday, November 06, 2009 11:45 AM
> >> To: hive-user@hadoop.apache.org
> >> Subject: Re: Problem installing Hive on hadoop 0.20.1
> >>
> >> can you try under /usr/local/hive
> >>
> >> $ ./bin/hive
> >>
> >> or
> >>
> >> $ cd /usr/local/hive/bin
> >> $ ./hive
> >>
> >> if it doesn't work, also try to cd your build/dist/bin/ and run ./
> >> hive
> >> over there.
> >>
> >> hive is a shell script and it uses some tricks like cd $var;pwd to
> >> decide which directory hive is running, based on which decide where
> >> are the jar files etc. I think bin/hive may have problems when you
> >> have $PATH which have other directories have subdirectory bin/hive.
> >> Or
> >> if you have $CDPATH set, you may also have problems.
> >>
> >> Ning
> >>
> >> On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:
> >>
> >>> Ning, thanks for the reply.
> >>> I do have all the files under /usr/local/hive and $HADOOP_HOME is
> >>> also set:
> >>>
> >>> hadoop@hadoop-1:/usr/local/hive$ ls
> >>> bin  conf  examples  lib  README.txt
> >>> hadoop@hadoop-1:/usr/local/hive$ ls lib
> >>> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3-
> >>> SNAPSHOT.jar
> >>> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
> >>> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
> >>> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
> >>> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
> >>> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
> >>> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
> >>> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
> >>> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
> >>> datanucleus-enhancer-1.1.2.jar  hive_serde.jar
> >>> stringtemplate-3.1b1.jar
> >>> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
> >>> derby.jar                       hive_shims.jar
> >>> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
> >>> /usr/local/hadoop
> >>>
> >>> That is why I'm confused.
> >>>
> >>> -----Original Message-----
> >>> From: Ning Zhang [mailto:nzhang@facebook.com]
> >>> Sent: Friday, November 06, 2009 11:25 AM
> >>> To: hive-user@hadoop.apache.org
> >>> Subject: Re: Problem installing Hive on hadoop 0.20.1
> >>>
> >>> It seems you don't have the jar files installed under /usr/local/
> >>> hive.
> >>> When you install hive, make sure to copy all files/subdirectories
> >>> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be
> >>> set.
> >>>
> >>> Ning
> >>>
> >>> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
> >>>
> >>>> Hi,
> >>>>
> >>>> I have a 2 node hadoop/hbase cluster which is working fine.
> >>>> hadoop was installed based on instructions at
> http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)<http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_%28Multi-Node_Cluster%29>
> >>>>
> >>>> I followed hive installation instructions at
> http://wiki.apache.org/hadoop/Hive/GettingStarted
> >>>> .
> >>>> When I try to run hive CLI, I get the following error:
> >>>>
> >>>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
> >>>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
> >>>> apache/hadoop/hive/conf/HiveConf
> >>>>     at java.lang.Class.forName0(Native Method)
> >>>>     at java.lang.Class.forName(Class.java:247)
> >>>>     at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
> >>>> Caused by: java.lang.ClassNotFoundException:
> >>>> org.apache.hadoop.hive.conf.HiveConf
> >>>>     at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> >>>>     at java.security.AccessController.doPrivileged(Native Method)
> >>>>     at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> >>>>     at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> >>>>     at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
> >>>>     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
> >>>> 320)
> >>>>     ... 3 more
> >>>>
> >>>> Any help is greatly appreciated.
> >>>> Massoud
> >>>
> >>
> >
>
>


-- 
Yours,
Zheng

Re: Problem installing Hive on hadoop 0.20.1

Posted by Ning Zhang <nz...@facebook.com>.
Sorry there was a typo in my previous email: please replace testcaes  
to testcase in the unit test command.  Basically if the unit tests do  
not pass, the hive distribution is not working. I suggest you check  
out a brand new trunk and try 'ant package' followed by ant test of  
one of the unit test qfile (e.g., create_1.q).

If that still fails, please open a JIRA under hadoop/Hive and include  
all the info about the environment and steps you have done and also  
post the log file under your build/ql/tmp/hive.log after you have run  
the one unit test.

Ning

On Nov 6, 2009, at 11:13 AM, Massoud Mazar wrote:

> I tried both trunk and /tags/release-0.4.0 (currently using 0.4.0)
> $JAVA_HOME points to /usr/lib/jvm/java-6-sun
> I'm using ubuntu server, so I guess it is bash
>
> ant test -Dtestcaes=TestCliDriver -Dqfile=create_1.q
> says (at the end)
>
> BUILD FAILED
> /tmp/hive/build.xml:142: The following error occurred while  
> executing this line:
> /tmp/hive/build.xml:89: The following error occurred while executing  
> this line:
> /tmp/hive/build-common.xml:316: Tests failed!
>
> -----Original Message-----
> From: Ning Zhang [mailto:nzhang@facebook.com]
> Sent: Friday, November 06, 2009 1:29 PM
> To: hive-user@hadoop.apache.org
> Subject: Re: Problem installing Hive on hadoop 0.20.1
>
> Are you using Hive trunk or branch-0.4? Which version of Java
> $JAVA_HOME is pointing to? Which shell are you using (csh/bash...)?
> Are you able to run some unit test under your "build directory" (the
> directory which contains build/dist), say  ant test -
> Dtestcaes=TestCliDriver -Dqfile=create_1.q
>
>  Ning
>
> On Nov 6, 2009, at 9:00 AM, Massoud Mazar wrote:
>
>> Tried all paths suggested, still get the same error. $CDPATH is
>> empty and
>>
>> hadoop@hadoop-1:/usr/local/hive/bin$ echo $PATH
>> /usr/local/bin:/usr/bin:/bin
>>
>> -----Original Message-----
>> From: Ning Zhang [mailto:nzhang@facebook.com]
>> Sent: Friday, November 06, 2009 11:45 AM
>> To: hive-user@hadoop.apache.org
>> Subject: Re: Problem installing Hive on hadoop 0.20.1
>>
>> can you try under /usr/local/hive
>>
>> $ ./bin/hive
>>
>> or
>>
>> $ cd /usr/local/hive/bin
>> $ ./hive
>>
>> if it doesn't work, also try to cd your build/dist/bin/ and run ./ 
>> hive
>> over there.
>>
>> hive is a shell script and it uses some tricks like cd $var;pwd to
>> decide which directory hive is running, based on which decide where
>> are the jar files etc. I think bin/hive may have problems when you
>> have $PATH which have other directories have subdirectory bin/hive.  
>> Or
>> if you have $CDPATH set, you may also have problems.
>>
>> Ning
>>
>> On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:
>>
>>> Ning, thanks for the reply.
>>> I do have all the files under /usr/local/hive and $HADOOP_HOME is
>>> also set:
>>>
>>> hadoop@hadoop-1:/usr/local/hive$ ls
>>> bin  conf  examples  lib  README.txt
>>> hadoop@hadoop-1:/usr/local/hive$ ls lib
>>> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3-
>>> SNAPSHOT.jar
>>> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
>>> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
>>> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
>>> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
>>> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
>>> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
>>> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
>>> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
>>> datanucleus-enhancer-1.1.2.jar  hive_serde.jar
>>> stringtemplate-3.1b1.jar
>>> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
>>> derby.jar                       hive_shims.jar
>>> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
>>> /usr/local/hadoop
>>>
>>> That is why I'm confused.
>>>
>>> -----Original Message-----
>>> From: Ning Zhang [mailto:nzhang@facebook.com]
>>> Sent: Friday, November 06, 2009 11:25 AM
>>> To: hive-user@hadoop.apache.org
>>> Subject: Re: Problem installing Hive on hadoop 0.20.1
>>>
>>> It seems you don't have the jar files installed under /usr/local/
>>> hive.
>>> When you install hive, make sure to copy all files/subdirectories
>>> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be
>>> set.
>>>
>>> Ning
>>>
>>> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
>>>
>>>> Hi,
>>>>
>>>> I have a 2 node hadoop/hbase cluster which is working fine.
>>>> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>>>>
>>>> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted
>>>> .
>>>> When I try to run hive CLI, I get the following error:
>>>>
>>>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
>>>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
>>>> apache/hadoop/hive/conf/HiveConf
>>>>     at java.lang.Class.forName0(Native Method)
>>>>     at java.lang.Class.forName(Class.java:247)
>>>>     at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
>>>> Caused by: java.lang.ClassNotFoundException:
>>>> org.apache.hadoop.hive.conf.HiveConf
>>>>     at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>>>     at java.security.AccessController.doPrivileged(Native Method)
>>>>     at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>>>     at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>>>     at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>>>     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
>>>> 320)
>>>>     ... 3 more
>>>>
>>>> Any help is greatly appreciated.
>>>> Massoud
>>>
>>
>


RE: Problem installing Hive on hadoop 0.20.1

Posted by Massoud Mazar <Ma...@avg.com>.
I tried both trunk and /tags/release-0.4.0 (currently using 0.4.0)
$JAVA_HOME points to /usr/lib/jvm/java-6-sun
I'm using ubuntu server, so I guess it is bash

ant test -Dtestcaes=TestCliDriver -Dqfile=create_1.q
says (at the end)

BUILD FAILED
/tmp/hive/build.xml:142: The following error occurred while executing this line:
/tmp/hive/build.xml:89: The following error occurred while executing this line:
/tmp/hive/build-common.xml:316: Tests failed!

-----Original Message-----
From: Ning Zhang [mailto:nzhang@facebook.com] 
Sent: Friday, November 06, 2009 1:29 PM
To: hive-user@hadoop.apache.org
Subject: Re: Problem installing Hive on hadoop 0.20.1

Are you using Hive trunk or branch-0.4? Which version of Java  
$JAVA_HOME is pointing to? Which shell are you using (csh/bash...)?  
Are you able to run some unit test under your "build directory" (the  
directory which contains build/dist), say  ant test - 
Dtestcaes=TestCliDriver -Dqfile=create_1.q

  Ning

On Nov 6, 2009, at 9:00 AM, Massoud Mazar wrote:

> Tried all paths suggested, still get the same error. $CDPATH is  
> empty and
>
> hadoop@hadoop-1:/usr/local/hive/bin$ echo $PATH
> /usr/local/bin:/usr/bin:/bin
>
> -----Original Message-----
> From: Ning Zhang [mailto:nzhang@facebook.com]
> Sent: Friday, November 06, 2009 11:45 AM
> To: hive-user@hadoop.apache.org
> Subject: Re: Problem installing Hive on hadoop 0.20.1
>
> can you try under /usr/local/hive
>
> $ ./bin/hive
>
> or
>
> $ cd /usr/local/hive/bin
> $ ./hive
>
> if it doesn't work, also try to cd your build/dist/bin/ and run ./hive
> over there.
>
> hive is a shell script and it uses some tricks like cd $var;pwd to
> decide which directory hive is running, based on which decide where
> are the jar files etc. I think bin/hive may have problems when you
> have $PATH which have other directories have subdirectory bin/hive. Or
> if you have $CDPATH set, you may also have problems.
>
> Ning
>
> On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:
>
>> Ning, thanks for the reply.
>> I do have all the files under /usr/local/hive and $HADOOP_HOME is
>> also set:
>>
>> hadoop@hadoop-1:/usr/local/hive$ ls
>> bin  conf  examples  lib  README.txt
>> hadoop@hadoop-1:/usr/local/hive$ ls lib
>> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3-
>> SNAPSHOT.jar
>> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
>> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
>> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
>> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
>> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
>> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
>> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
>> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
>> datanucleus-enhancer-1.1.2.jar  hive_serde.jar
>> stringtemplate-3.1b1.jar
>> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
>> derby.jar                       hive_shims.jar
>> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
>> /usr/local/hadoop
>>
>> That is why I'm confused.
>>
>> -----Original Message-----
>> From: Ning Zhang [mailto:nzhang@facebook.com]
>> Sent: Friday, November 06, 2009 11:25 AM
>> To: hive-user@hadoop.apache.org
>> Subject: Re: Problem installing Hive on hadoop 0.20.1
>>
>> It seems you don't have the jar files installed under /usr/local/ 
>> hive.
>> When you install hive, make sure to copy all files/subdirectories
>> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be  
>> set.
>>
>> Ning
>>
>> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
>>
>>> Hi,
>>>
>>> I have a 2 node hadoop/hbase cluster which is working fine.
>>> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>>>
>>> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted
>>> .
>>> When I try to run hive CLI, I get the following error:
>>>
>>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
>>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
>>> apache/hadoop/hive/conf/HiveConf
>>>      at java.lang.Class.forName0(Native Method)
>>>      at java.lang.Class.forName(Class.java:247)
>>>      at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.apache.hadoop.hive.conf.HiveConf
>>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>>      at java.security.AccessController.doPrivileged(Native Method)
>>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
>>> 320)
>>>      ... 3 more
>>>
>>> Any help is greatly appreciated.
>>> Massoud
>>
>


Re: Problem installing Hive on hadoop 0.20.1

Posted by Ning Zhang <nz...@facebook.com>.
Are you using Hive trunk or branch-0.4? Which version of Java  
$JAVA_HOME is pointing to? Which shell are you using (csh/bash...)?  
Are you able to run some unit test under your "build directory" (the  
directory which contains build/dist), say  ant test - 
Dtestcaes=TestCliDriver -Dqfile=create_1.q

  Ning

On Nov 6, 2009, at 9:00 AM, Massoud Mazar wrote:

> Tried all paths suggested, still get the same error. $CDPATH is  
> empty and
>
> hadoop@hadoop-1:/usr/local/hive/bin$ echo $PATH
> /usr/local/bin:/usr/bin:/bin
>
> -----Original Message-----
> From: Ning Zhang [mailto:nzhang@facebook.com]
> Sent: Friday, November 06, 2009 11:45 AM
> To: hive-user@hadoop.apache.org
> Subject: Re: Problem installing Hive on hadoop 0.20.1
>
> can you try under /usr/local/hive
>
> $ ./bin/hive
>
> or
>
> $ cd /usr/local/hive/bin
> $ ./hive
>
> if it doesn't work, also try to cd your build/dist/bin/ and run ./hive
> over there.
>
> hive is a shell script and it uses some tricks like cd $var;pwd to
> decide which directory hive is running, based on which decide where
> are the jar files etc. I think bin/hive may have problems when you
> have $PATH which have other directories have subdirectory bin/hive. Or
> if you have $CDPATH set, you may also have problems.
>
> Ning
>
> On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:
>
>> Ning, thanks for the reply.
>> I do have all the files under /usr/local/hive and $HADOOP_HOME is
>> also set:
>>
>> hadoop@hadoop-1:/usr/local/hive$ ls
>> bin  conf  examples  lib  README.txt
>> hadoop@hadoop-1:/usr/local/hive$ ls lib
>> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3-
>> SNAPSHOT.jar
>> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
>> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
>> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
>> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
>> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
>> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
>> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
>> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
>> datanucleus-enhancer-1.1.2.jar  hive_serde.jar
>> stringtemplate-3.1b1.jar
>> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
>> derby.jar                       hive_shims.jar
>> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
>> /usr/local/hadoop
>>
>> That is why I'm confused.
>>
>> -----Original Message-----
>> From: Ning Zhang [mailto:nzhang@facebook.com]
>> Sent: Friday, November 06, 2009 11:25 AM
>> To: hive-user@hadoop.apache.org
>> Subject: Re: Problem installing Hive on hadoop 0.20.1
>>
>> It seems you don't have the jar files installed under /usr/local/ 
>> hive.
>> When you install hive, make sure to copy all files/subdirectories
>> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be  
>> set.
>>
>> Ning
>>
>> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
>>
>>> Hi,
>>>
>>> I have a 2 node hadoop/hbase cluster which is working fine.
>>> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>>>
>>> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted
>>> .
>>> When I try to run hive CLI, I get the following error:
>>>
>>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
>>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
>>> apache/hadoop/hive/conf/HiveConf
>>>      at java.lang.Class.forName0(Native Method)
>>>      at java.lang.Class.forName(Class.java:247)
>>>      at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
>>> Caused by: java.lang.ClassNotFoundException:
>>> org.apache.hadoop.hive.conf.HiveConf
>>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>>      at java.security.AccessController.doPrivileged(Native Method)
>>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
>>> 320)
>>>      ... 3 more
>>>
>>> Any help is greatly appreciated.
>>> Massoud
>>
>


RE: Problem installing Hive on hadoop 0.20.1

Posted by Massoud Mazar <Ma...@avg.com>.
Tried all paths suggested, still get the same error. $CDPATH is empty and 

hadoop@hadoop-1:/usr/local/hive/bin$ echo $PATH
/usr/local/bin:/usr/bin:/bin

-----Original Message-----
From: Ning Zhang [mailto:nzhang@facebook.com] 
Sent: Friday, November 06, 2009 11:45 AM
To: hive-user@hadoop.apache.org
Subject: Re: Problem installing Hive on hadoop 0.20.1

can you try under /usr/local/hive

$ ./bin/hive

or

$ cd /usr/local/hive/bin
$ ./hive

if it doesn't work, also try to cd your build/dist/bin/ and run ./hive  
over there.

hive is a shell script and it uses some tricks like cd $var;pwd to  
decide which directory hive is running, based on which decide where  
are the jar files etc. I think bin/hive may have problems when you  
have $PATH which have other directories have subdirectory bin/hive. Or  
if you have $CDPATH set, you may also have problems.

Ning

On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:

> Ning, thanks for the reply.
> I do have all the files under /usr/local/hive and $HADOOP_HOME is  
> also set:
>
> hadoop@hadoop-1:/usr/local/hive$ ls
> bin  conf  examples  lib  README.txt
> hadoop@hadoop-1:/usr/local/hive$ ls lib
> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3- 
> SNAPSHOT.jar
> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
> datanucleus-enhancer-1.1.2.jar  hive_serde.jar       
> stringtemplate-3.1b1.jar
> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
> derby.jar                       hive_shims.jar
> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
> /usr/local/hadoop
>
> That is why I'm confused.
>
> -----Original Message-----
> From: Ning Zhang [mailto:nzhang@facebook.com]
> Sent: Friday, November 06, 2009 11:25 AM
> To: hive-user@hadoop.apache.org
> Subject: Re: Problem installing Hive on hadoop 0.20.1
>
> It seems you don't have the jar files installed under /usr/local/hive.
> When you install hive, make sure to copy all files/subdirectories
> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be set.
>
> Ning
>
> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
>
>> Hi,
>>
>> I have a 2 node hadoop/hbase cluster which is working fine.
>> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>>
>> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted
>> .
>> When I try to run hive CLI, I get the following error:
>>
>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
>> apache/hadoop/hive/conf/HiveConf
>>       at java.lang.Class.forName0(Native Method)
>>       at java.lang.Class.forName(Class.java:247)
>>       at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
>> Caused by: java.lang.ClassNotFoundException:
>> org.apache.hadoop.hive.conf.HiveConf
>>       at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>       at java.security.AccessController.doPrivileged(Native Method)
>>       at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>       at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>       at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
>> 320)
>>       ... 3 more
>>
>> Any help is greatly appreciated.
>> Massoud
>


Re: Problem installing Hive on hadoop 0.20.1

Posted by Ning Zhang <nz...@facebook.com>.
can you try under /usr/local/hive

$ ./bin/hive

or

$ cd /usr/local/hive/bin
$ ./hive

if it doesn't work, also try to cd your build/dist/bin/ and run ./hive  
over there.

hive is a shell script and it uses some tricks like cd $var;pwd to  
decide which directory hive is running, based on which decide where  
are the jar files etc. I think bin/hive may have problems when you  
have $PATH which have other directories have subdirectory bin/hive. Or  
if you have $CDPATH set, you may also have problems.

Ning

On Nov 6, 2009, at 8:29 AM, Massoud Mazar wrote:

> Ning, thanks for the reply.
> I do have all the files under /usr/local/hive and $HADOOP_HOME is  
> also set:
>
> hadoop@hadoop-1:/usr/local/hive$ ls
> bin  conf  examples  lib  README.txt
> hadoop@hadoop-1:/usr/local/hive$ ls lib
> antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3- 
> SNAPSHOT.jar
> asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
> commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
> commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
> commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
> commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
> commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
> commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
> datanucleus-core-1.1.2.jar      hive_metastore.jar  py
> datanucleus-enhancer-1.1.2.jar  hive_serde.jar       
> stringtemplate-3.1b1.jar
> datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
> derby.jar                       hive_shims.jar
> hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
> /usr/local/hadoop
>
> That is why I'm confused.
>
> -----Original Message-----
> From: Ning Zhang [mailto:nzhang@facebook.com]
> Sent: Friday, November 06, 2009 11:25 AM
> To: hive-user@hadoop.apache.org
> Subject: Re: Problem installing Hive on hadoop 0.20.1
>
> It seems you don't have the jar files installed under /usr/local/hive.
> When you install hive, make sure to copy all files/subdirectories
> under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be set.
>
> Ning
>
> On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:
>
>> Hi,
>>
>> I have a 2 node hadoop/hbase cluster which is working fine.
>> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>>
>> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted
>> .
>> When I try to run hive CLI, I get the following error:
>>
>> hadoop@hadoop-1:/usr/local/hive$ bin/hive
>> Exception in thread "main" java.lang.NoClassDefFoundError: org/
>> apache/hadoop/hive/conf/HiveConf
>>       at java.lang.Class.forName0(Native Method)
>>       at java.lang.Class.forName(Class.java:247)
>>       at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
>> Caused by: java.lang.ClassNotFoundException:
>> org.apache.hadoop.hive.conf.HiveConf
>>       at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>       at java.security.AccessController.doPrivileged(Native Method)
>>       at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>       at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>       at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
>> 320)
>>       ... 3 more
>>
>> Any help is greatly appreciated.
>> Massoud
>


RE: Problem installing Hive on hadoop 0.20.1

Posted by Massoud Mazar <Ma...@avg.com>.
Ning, thanks for the reply.
I do have all the files under /usr/local/hive and $HADOOP_HOME is also set:

hadoop@hadoop-1:/usr/local/hive$ ls
bin  conf  examples  lib  README.txt
hadoop@hadoop-1:/usr/local/hive$ ls lib
antlr-runtime-3.0.1.jar         hive_anttasks.jar   jdo2-api-2.3-SNAPSHOT.jar
asm-3.1.jar                     hive_cli.jar        jline-0.9.94.jar
commons-cli-2.0-SNAPSHOT.jar    hive_common.jar     json.jar
commons-codec-1.3.jar           hive_contrib.jar    junit-3.8.1.jar
commons-collections-3.2.1.jar   hive_exec.jar       libfb303.jar
commons-lang-2.4.jar            hive_hwi.jar        libthrift.jar
commons-logging-1.0.4.jar       hive_hwi.war        log4j-1.2.15.jar
commons-logging-api-1.0.4.jar   hive_jdbc.jar       php
datanucleus-core-1.1.2.jar      hive_metastore.jar  py
datanucleus-enhancer-1.1.2.jar  hive_serde.jar      stringtemplate-3.1b1.jar
datanucleus-rdbms-1.1.2.jar     hive_service.jar    velocity-1.5.jar
derby.jar                       hive_shims.jar
hadoop@hadoop-1:/usr/local/hive$ echo $HADOOP_HOME
/usr/local/hadoop

That is why I'm confused.

-----Original Message-----
From: Ning Zhang [mailto:nzhang@facebook.com] 
Sent: Friday, November 06, 2009 11:25 AM
To: hive-user@hadoop.apache.org
Subject: Re: Problem installing Hive on hadoop 0.20.1

It seems you don't have the jar files installed under /usr/local/hive.  
When you install hive, make sure to copy all files/subdirectories  
under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be set.

Ning

On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:

> Hi,
>
> I have a 2 node hadoop/hbase cluster which is working fine.
> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>
> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted 
> .
> When I try to run hive CLI, I get the following error:
>
> hadoop@hadoop-1:/usr/local/hive$ bin/hive
> Exception in thread "main" java.lang.NoClassDefFoundError: org/ 
> apache/hadoop/hive/conf/HiveConf
>        at java.lang.Class.forName0(Native Method)
>        at java.lang.Class.forName(Class.java:247)
>        at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
> Caused by: java.lang.ClassNotFoundException:  
> org.apache.hadoop.hive.conf.HiveConf
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java: 
> 320)
>        ... 3 more
>
> Any help is greatly appreciated.
> Massoud


Re: Problem installing Hive on hadoop 0.20.1

Posted by Ning Zhang <nz...@facebook.com>.
It seems you don't have the jar files installed under /usr/local/hive.  
When you install hive, make sure to copy all files/subdirectories  
under build/dist to /usr/local/hive. Also $HADOOP_HOME need to be set.

Ning

On Nov 6, 2009, at 7:15 AM, Massoud Mazar wrote:

> Hi,
>
> I have a 2 node hadoop/hbase cluster which is working fine.
> hadoop was installed based on instructions at http://www.michael-noll.com/wiki/Running_Hadoop_On_Ubuntu_Linux_(Multi-Node_Cluster)
>
> I followed hive installation instructions at http://wiki.apache.org/hadoop/Hive/GettingStarted 
> .
> When I try to run hive CLI, I get the following error:
>
> hadoop@hadoop-1:/usr/local/hive$ bin/hive
> Exception in thread "main" java.lang.NoClassDefFoundError: org/ 
> apache/hadoop/hive/conf/HiveConf
>        at java.lang.Class.forName0(Native Method)
>        at java.lang.Class.forName(Class.java:247)
>        at org.apache.hadoop.util.RunJar.main(RunJar.java:149)
> Caused by: java.lang.ClassNotFoundException:  
> org.apache.hadoop.hive.conf.HiveConf
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java: 
> 320)
>        ... 3 more
>
> Any help is greatly appreciated.
> Massoud