我在配置HBase的时候遇到了这个bug,我认为bug在:
distMode=`$bin/hbase --config "$HBASE_CONF_DIR" org.apache.hadoop.hbase.util.HBaseConfTool hbase.cluster.distributed`
所以我将echo "alert(4)"
头部添加到hbase,但我找不到alert(4)
。
开始-hbase.sh(片段)
echo "alert(1)"
#start hbase daemons
errCode=$?
if [ $errCode -ne 0 ]
then
exit $errCode
fi
echo "alert(1.5)"
echo $HBASE_CONF_DIR
echo org.apache.hadoop.hbase.util.HBaseConfTool
echo hbase.cluster.distributed
distMode=`$bin/hbase --config "$HBASE_CONF_DIR" org.apache.hadoop.hbase.util.HBaseConfTool hbase.cluster.distributed`
echo "alert(2)"
echo $distMode
系统打印
bob1@master:~$ hbase-0.94.0/bin/start-hbase.sh
START_JAVA_HOME
alert(1)
alert(1.5)
/home/bob1/hbase-0.94.0/conf
org.apache.hadoop.hbase.util.HBaseConfTool
hbase.cluster.distributed
Exception in thread "main" java.lang.NoClassDefFoundError: /usr/lib/jvm/java-6-sun-1/6/0/24
Caused by: java.lang.ClassNotFoundException: .usr.lib.jvm.java-6-sun-1.6.0.24
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 sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: /usr/lib/jvm/java-6-sun-1.6.0.24. Program will exit.
alert(2)