目录
1、下载cdh parcels包
下载 CDH-5.9.1-1.cdh5.9.1.p0.4-el7.parcel
mkdir -p /opt/cloudera/parcels
cd /opt/cloudera/parcels
上传刚才的的parcel包至/opt/cloudera/parcels目录
tar -zxvf CDH-5.9.1-1.cdh5.9.1.p0.4-el7.parcel
ln -s CDH-5.9.1-1.cdh5.9.1.p0.4-el7.parcel CDH
下载配置
下载 hive-clientconfig.zip 和 hbase-clientconfig.zip 并解压
mkdir -p /opt/cloudera/etc/
[root@vm01 parcels]# ll /opt/cloudera/etc/
总用量 0
drwxr-xr-x 2 root root 154 1月 25 10:31 hadoop-conf
drwxr-xr-x 2 root root 153 1月 25 10:31 hbase-conf
drwxr-xr-x 2 root root 266 1月 25 10:31 hive-conf
2. 配置环境变量
#修改Hadoop客户端环境变量,将以下命令追加到/etc/profile里,确保每个用户都有同样一套环境变量
vi /etc/profile
export JAVA_HOME=/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64
export HADOOP_HOME=/opt/cloudera/parcels/CDH
export HIVE_HOME=/opt/cloudera/parcels/CDH/lib/hive
export HBASE_HOME=/opt/cloudera/parcels/CDH/lib/hbase
export HCAT_HOME=/opt/cloudera/parcels/CDH
export HADOOP_CONF_DIR=/opt/cloudera/etc/hive-conf
export HIVE_CONF=/opt/cloudera/etc/hive-conf/
export YARN_CONF_DIR=/opt/cloudera/etc/hive-conf
export CDH_MR2_HOME=$HADOOP_HOME/lib/hadoop-mapreduce
export PATH=${HADOOP_CONF_DIR}:${HADOOP_HOME}/bin:${HADOOP_HOME}/sbin:${HBASE_HOME}/bin:${HIVE_HOME}/bin:${HCAT_HOME}/bin:${PATH}
source /etc/profile
3. 在客户端服务器上配置hosts文件
配置集群的host
vi /etc/hosts
添加hosts配置
101.2.25.6 node001
101.2.25.7 node002
4.参考资料
CDH客户端安装_weixin_34117211的博客-CSDN博客