hadoop启动jar脚本

程序已经打成了jar包

通过添加classpath来启动jar

#!/bin/bash
cd /home/target

HIVE_HOME=/opt/cloudera/parcels/CDH/lib/hive
HBASE_HOME=/opt/cloudera/parcels/CDH/lib/hbase
KUDU_HOME=/opt/cloudera/parcels/CDH/lib/kudu

HADOOP_CLASSPATH=`${HBASE_HOME}/bin/hbase mapredcp`:${HBASE_HOME}/conf/*:${HIVE_HOME}/lib/*:${KUDU_HOME}/*:$HADOOP_CLASSPATH hadoop jar target.jar $1 $2 $3 $4

 

你可能感兴趣的:(随手小记)