CDH5.16.2安装部署(三) CDH部署

一、离线部署cm server及agent

1.1 拷贝cm包到其他节点

[root@hadoop001 cdh5162]# scp cloudera-manager-centos7-cm5.16.2_x86_64.tar.gz hadoop002:~/cdh5162/  
[root@hadoop001 cdh5162]# scp cloudera-manager-centos7-cm5.16.2_x86_64.tar.gz hadoop003:~/cdh5162/

1.2 所有节点创建目录及解压

[root@hadoop001 cdh5162]# mkdir /opt/cloudera-manager
[root@hadoop001 cdh5162]# tar -xf cloudera-manager-centos7-cm5.16.2_x86_64.tar.gz -C /opt/cloudera-manager/


1.3所有节点修改agent的配置,指向server的节点hadoop001

[root@hadoop001 cdh5162]# sed -i "s/server_host=localhost/server_host=hadoop001/g" /opt/cloudera-manager/cm-5.16.2/etc/cloudera-scm-agent/config.ini 

1.4 主节点修改server的配置

[root@hadoop001 cloudera-scm-server]# vi /opt/cloudera-manager/cm-5.16.2/etc/cloudera-scm-server/db.properties 

com.cloudera.cmf.db.type=mysql
com.cloudera.cmf.db.host=hadoop001
com.cloudera.cmf.db.name=cmf
com.cloudera.cmf.db.user=cmf
com.cloudera.cmf.db.password=cmf
com.cloudera.cmf.db.setupType=EXTERNAL

1.5 所有节点创建用户

[root@hadoop001 cloudera-scm-server]# useradd --system --home=/opt/cloudera-manager/cm-5.16.2/run/cloudera-scm-server/ --no-create-home --shell=/bin/false --comment "Cloudera SCM User" cloudera-scm 

1.6 目录修改用户及用户组

[root@hadoop001 cloudera-scm-server]# chown -R cloudera-scm:cloudera-scm /opt/cloudera-manager

二、主节点部署离线parcel源

2.1 部署离线parcel源

[root@hadoop001 cloudera-scm-server]# mkdir -p /opt/cloudera/parcel-repo

[root@hadoop001 cdh5162]# cp CDH-5.16.2-1.cdh5.16.2.p0.8-el7.parcel /opt/cloudera/parcel-repo/

#切记cp时,重命名去掉1,不然在部署过程CM认为如上⽂件下载未完整,会持续下载

[root@hadoop001 cdh5162]# cp CDH-5.16.2-1.cdh5.16.2.p0.8-el7.parcel.sha1 /opt/cloudera/parcel-repo/CDH-5.16.2-1.cdh5.16.2.p0.8-el7.parcel.sha
[root@hadoop001 cdh5162]# cp manifest.json /opt/cloudera/parcel-repo/
[root@hadoop001 parcel-repo]# ll
total 2082872
-rw-r--r-- 1 root root 2132782197 May 17 17:29 CDH-5.16.2-1.cdh5.16.2.p0.8-el7.parcel
-rw-r--r-- 1 root root         41 May 17 17:30 CDH-5.16.2-1.cdh5.16.2.p0.8-el7.parcel.sha
-rw-r--r-- 1 root root      66804 May 17 17:30 manifest.json

2.2 目录修改用户及用户组

[root@hadoop001 parcel-repo]#  chown -R cloudera-scm:cloudera-scm /opt/cloudera/


三、所有节点创建软件安装目录、用户及用户组权限

[root@hadoop001 parcel-repo]# mkdir -p /opt/cloudera/parcels 
[root@hadoop001 parcel-repo]# chown -R cloudera-scm:cloudera-scm /opt/cloudera/

四、hadoop001节点启动Server

[root@hadoop001 parcel-repo]# /opt/cloudera-manager/cm-5.16.2/etc/init.d/cloudera-scm-server start
Starting cloudera-scm-server:                              [  OK  ]

阿⾥云web界⾯,设置该hadoop001节点防⽕墙放开7180端⼝

CDH5.16.2安装部署(三) CDH部署_第1张图片

五、所有节点启动Agent

[root@hadoop001 parcel-repo]# /opt/cloudera-manager/cm-5.16.2/etc/init.d/cloudera-scm-agent start
Starting cloudera-scm-agent:                               [  OK  ]

六、接下来,全部Web界面操作

http://hadoop001:7180/

账号密码:admin/admin

6.1 首页

CDH5.16.2安装部署(三) CDH部署_第2张图片

6.2当前管理的主机,开启c'loudera agent服务的

 

CDH5.16.2安装部署(三) CDH部署_第3张图片

6.3 选择存储库

 

CDH5.16.2安装部署(三) CDH部署_第4张图片

6.4检查主机正确性

 

CDH5.16.2安装部署(三) CDH部署_第5张图片
6.5 修改配置

[root@hadoop001 parcel-repo]# vi /etc/sysctl.conf 

vm.swappiness=10

[root@hadoop001 parcel-repo]# vi /etc/rc.d/rc.local 
 

echo never > /sys/kernel/mm/transparent_hugepage/defrag 
echo never > /sys/kernel/mm/transparent_hugepage/enabled

# centos7.x系统,需要为"/etc/rc.d/rc.local"⽂件赋予执⾏权限

[root@hadoop001 parcel-repo]# chmod +x /etc/rc.d/rc.local

6.6  安装HDFS、YARN、Zookeeper
 

CDH5.16.2安装部署(三) CDH部署_第6张图片

6.7 连接数据库

 

CDH5.16.2安装部署(三) CDH部署_第7张图片

6.8安装完成

 

CDH5.16.2安装部署(三) CDH部署_第8张图片

你可能感兴趣的:(大数据,CDH)