Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
HBase >> mail # user >> Loading hbase-site.xml settings from Hadoop MR job


Copy link to this message
-
Loading hbase-site.xml settings from Hadoop MR job
I'm having an issue where my Hadoop MR job for bulk loading data into Hbase
is not reading my hbase-site.xml file -- thus it tries to connect to
Zookeeper on localhost.  This is on a cluster using CDH4 on Ubuntu 12.04.

Here's the code where it attempts to connect to local zookeeper:
    Configuration conf = new Configuration(); // from org.apache.hadoop.conf
    Job job = new Job(conf);
    HTable hTable = new HTable(conf, tableName);
    HFileOutputFormat.configureIncrementalLoad(job, hTable);

As suggested by another thread I came across, I've added "/etc/hbase/conf/"
to my HADOOP_CLASSPATH (in /etc/hadoop/conf/hadoop-env.sh), restarted
services, but no improvement. Here is the full classpath:

/usr/local/hadoop/lib/hadoop-lzo-0.4.17-SNAPSHOT.jar:/etc/hbase/conf/::/etc/hadoop/conf:/usr/lib/hadoop/lib/*:/usr/lib/hadoop/.//*:/usr/lib/hadoop-hdfs/./:/usr/lib/hadoop-hdfs/lib/*:/usr/lib/hadoop-hdfs/.//*:/usr/lib/hadoop-yarn/lib/*:/usr/lib/hadoop-yarn/.//*:/usr/lib/hadoop-0.20-mapreduce/./:/usr/lib/hadoop-0.20-mapreduce/lib/*:/usr/lib/hadoop-0.20-mapreduce/.//*

Any thoughts on what the problem could be?
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB