-Re: Hive Getting Started Wiki assumes $CLASSPATH at end of HADOOP_CLASSPATH
Please see Edward's reply to 'Exception in hive startup' on Oct 13th.
Try running with <install-dir>/bin/hive
On Mon, Nov 8, 2010 at 7:02 PM, Stuart Smith <[EMAIL PROTECTED]> wrote:
> I'm just starting with hive, and I ran into a newbie problem that didn't
> have a solution via google. So I thought I'd record the solution for
> posterity (and other hapless newbies) :)
> I've been using hadoop/hbase for a while, and have configured hadoop-env.sh
> a bit here and there (to work with hbase, etc). At some point, I dropped the
> $CLASSPATH off the end of the standard line:
> So it became:
> # Extra Java CLASSPATH elements. Optional.
> (probably when I added the hbase stuff or something). My hadoop/hbase set
> up runs fine, so I never noticed.
> Well, if you do that, and you try to run the hive shell, you get the:
> stu@ubuntu-update:~/hive-0.6.0/bin/ext$ /home/stu/hadoop-0.20.2/bin/hadoop
> jar /home/stu/hive-0.6.0/lib/hive-cli-0.6.0.jar
> Exception in thread "main" java.lang.NoClassDefFoundError:
> 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:
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> ... 3 more
> error, even if you've followed the wiki correctly and set HADOOP_HOME and
> HIVE_HOME correctly. Note the command line above is a little strange,
> because I was debugging through the $HIVE_HOME/bin/hive script... (So I
> printed out the classpath it was forming, set it by hand, ran the
> instructions by hand, etc).
> This is installing from the hive tar (stable). But that doesn't matter.
> Anyways, hope the answer helps someone..