这里我们选择第二种安装方式
安装环境:
192.168.101.115 安装cloudera-manager-daemons,cloudera-manager-agent和cloudera-manager-server
192.168.101.116 安装cloudera-manager-daemons和cloudera-manager-agent
192.168.100.217 安装cloudera-manager-daemons和cloudera-manager-agent
192.168.100.225 安装cloudera-manager-daemons和cloudera-manager-agent
1.配置SSH透明登录
ssh-keygen -t rsa
cd .ssh
ssh-copy-id -i id_rsa.pub 192.168.100.217
ssh-copy-id -i id_rsa.pub 192.168.100.225
ssh-copy-id -i id_rsa.pub 192.168.101.116
每台服务器都配置透明登录
2.jdk安装
之前apache hadoop安装过,见http://blog.163.com/dazuiba_008/blog/static/363349812017115102750779/
这里加上在.bash_profile中加入JAVA_HOME=/usr/local/jdk1.8.0_121
PATH加入/usr/local/jdk1.8.0_121/bin
如果没有安装jdk
yum安装jdk
yum install -y oracle-j2sdk1.7
3.安装CM
安装包下载地址:
Cloudera文档汇总
http://www.cloudera.com/content/support/en/documentation.html
CDH5包汇总
http://archive.cloudera.com/cdh5/
CM5包汇总
http://archive.cloudera.com/cm5/
下载后安装:
安装依赖包
yum install -y MySQL-python mod_ssl python-psycopg2 fuse fuse-libs
安装cm组件
rpm -ivh cloudera-manager-server-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm cloudera-manager-daemons-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm cloudera-manager-agent-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm
如果可以访问外网,可以配置yum源
[cloudera-manager]
# Packages for Cloudera Manager, Version 5, on RedHat or CentOS 6 x86_64
name=Cloudera Manager
baseurl=https://archive.cloudera.com/cm5/redhat/6/x86_64/cm/5/
gpgkey =https://archive.cloudera.com/cm5/redhat/6/x86_64/cm/RPM-GPG-KEY-cloudera
gpgcheck = 1
yum install -y cloudera-manager-daemons cloudera-manager-server
我们这里用PG,PG安装这里略,建立相关数据库,修改cloudera manager数据库配置
postgres=# CREATE ROLE scm LOGIN PASSWORD 'scm';
postgres=# CREATE DATABASE scm OWNER scm ENCODING 'UTF8';
cat /etc/cloudera-scm-server/db.properties
com.cloudera.cmf.db.type=postgresql
com.cloudera.cmf.db.host=localhost:1921
com.cloudera.cmf.db.name=scm
com.cloudera.cmf.db.user=scm
com.cloudera.cmf.db.password=scm
com.cloudera.cmf.db.setupType=EXTERNAL
修改PG的pg_hba.conf配置文件,可以访问scm数据库
启动服务:
service cloudera-scm-server start
启动期间监控日志:
tail -f /var/log/cloudera-scm-server/cloudera-scm-server.log
http://192.168.101.115:7180/cmf/login 打开管理页面