准备好CDH安装包资源,官方网站下载需要账号,如果没有账号可以去网上到处搜搜。主要涉及到的资源有:
yum install mariadb-server
systemctl enable mariadb
systemctl start mariadb
mysql_secure_installation
若CM服务与数据库不在同一台机器上,需要对数据库进行设置,使其允许其他机器IP远程访问数据库。这点非常重要,否则将会导致CM初始化数据库失败。
yum install cloudera-manager-server-6.3.1-1466458.el7.x86_64.rpm cloudera-manager-daemons-6.3.1-1466458.el7.x86_64.rpm
vim /etc/cloudera-scm-server/db.properties
# Copyright (c) 2012 Cloudera, Inc. All rights reserved.
#
# This file describes the database connection.
#
# The database type
# Currently 'mysql', 'postgresql' and 'oracle' are valid databases.
com.cloudera.cmf.db.type=mysql
# The database host
# If a non standard port is needed, use 'hostname:port'
com.cloudera.cmf.db.host=mariadb-server-ip:port
# The database name
com.cloudera.cmf.db.name=cmf
# The database user
com.cloudera.cmf.db.user=<用户名>
# The database user's password
com.cloudera.cmf.db.password=<数据库密码>
# The db setup type
# After fresh install it is set to INIT
# and will be changed post config.
# If scm-server uses Embedded DB then it is set to EMBEDDED
# If scm-server uses External DB then it is set to EXTERNAL
com.cloudera.cmf.db.setupType=EXTERNAL
cp mysql-connector-java-6.0.6.jar /usr/share/java/mysql-connector-java.jar
CDH-6.3.2-1.cdh6.3.2.p0.1605554-el7.parcel
CDH-6.3.2-1.cdh6.3.2.p0.1605554-el7.parcel.sha
CDH-6.3.2-1.cdh6.3.2.p0.1605554-el7.parcel.sha1
CDH-6.3.2-1.cdh6.3.2.p0.1605554-el7.parcel.sha256
manifest.json
systemctl start cloudera-scm-server
CM服务是集群的管理节点,CM负责管理大数据集群内所有的数据节点,数据节点上需要部署 agent 服务,agent服务负责与CM服务通信,CM 服务通过 agent 服务来管理集群内所有的数据节点。
yum install cloudera-manager-agent-6.3.1-1466458.el7.x86_64.rpm cloudera-manager-daemons-6.3.1-1466458.el7.x86_64.rpm
vim /etc/cloudera-scm-agent/config.ini
[General]
# Hostname of the CM server.
server_host=k8s-node1
# Port that the CM server is listening on.
server_port=7182
systemctl start cloudera-scm-agent
CM服务默认端口是 7180, 默认账号以及初始密码是:admin/admin。请确保 7180 端口没有被防火墙禁止。登录系统后将会做基础的配置,根据需要选择合适的版本,企业版需要购买License,Express 版本免费使用,但是支持的功能有限。