CentOS 7安裝Cloudera完整指南
前置條件
- CentOS 7操作系統(tǒng)(最小化安裝)
- root或sudo權(quán)限用戶
- 至少4GB內(nèi)存及20GB磁盤空間
- 網(wǎng)絡(luò)連通性(建議關(guān)閉防火墻或開放7180/7182端口)
步驟1:系統(tǒng)環(huán)境配置
禁用SELinux
sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
setenforce 0
安裝基礎(chǔ)依賴
yum install -y wget ntp openssl-devel python3
配置NTP時(shí)間同步
systemctl enable ntpd
systemctl start ntpd
步驟2:安裝Cloudera Manager
添加Cloudera倉庫
wget https://archive.cloudera.com/cm7/7.9.3/cloudera-manager.repo -P /etc/yum.repos.d/
yum clean all
安裝服務(wù)端與代理
yum install -y cloudera-manager-server cloudera-manager-agent
步驟3:數(shù)據(jù)庫配置(以MySQL為例)
yum install -y mariadb-server mariadb
systemctl start mariadb
mysql_secure_installation
創(chuàng)建Cloudera元數(shù)據(jù)庫并授權(quán)用戶訪問權(quán)限。
步驟4:?jiǎn)?dòng)Cloudera服務(wù)
/opt/cloudera/cm/schema/scm_prepare_database.sh mysql scm scm scm_password
systemctl start cloudera-scm-server
systemctl start cloudera-scm-agent
通過瀏覽器訪問 http://服務(wù)器IP:7180 完成Web向?qū)渲谩?/p>
故障排查提示
- 檢查
/var/log/cloudera-scm-server/
日志文件 - 驗(yàn)證主機(jī)名解析與SSH免密登錄配置
- 確認(rèn)JDK版本與Cloudera兼容性