cloudera manager5.11.0離線安裝詳細步驟
阿新 • • 發佈:2019-01-11
第一步: (下載安裝包)
第二步: (使用本地CentOS映象源)
[[email protected] ~]# cd /etc/yum.repos.d/
[[email protected] yum.repos.d]# ls
backup CentOS-Base.repo epel.repo
[[email protected] yum.repos.d]# mv epel.repo epel.repo.bak
[[email protected] yum.repos.d]# yum clean all(清理快取)
[[email protected] yum.repos.d]# yum list
第三步: (下載Cloudera Agent所依賴的包)
yum install -y cyrus-sasl-plain cyrus-sasl-gssapi portmap
yum install -y fuse-libs bind-utils libxslt
yum install -y /lib/lsb/init-functions
yum install -y mod_ssl openssl-devel python-psycopg2 MySQL-python
第四步: (安裝Httpd服務)
[root@hadoop06 ~]# yum install httpd -y
[root@hadoop06 ~]# service httpd start
[root@hadoop06 ~]# chkconfig httpd on
[root@hadoop06 ~]# chkconfig httpd on
[root@hadoop06 ~]# cd /var/www/html
[root@hadoop06 html]# mkdir -p cm5/redhat/6/x86_64/cm/5/RPMS/x86_64/
第五步: (配置repodata目錄)
[root@hadoop06 cm] yum install -y createrepo deltarpm python-deltarpm
[root@hadoop 06 cm] cd /var/www/html/cm5/redhat/6/x86_64/cm/5/
[root@hadoop06 cm] createrepo .
Spawning worker 0 with 7 pkgs
Workers Finished
Gathering worker results
Saving Primary metadata
Saving file lists metadata
Saving other metadata
Generating sqlite DBs
Sqlite DBs complete
第六步: (配置Httpd本地服務源)
[[email protected] software]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.111.128 hadoop06 archive.cloudera.com
192.168.111.129 hadoop07
[[email protected] html]# cd /etc/yum.repos.d
[[email protected] yum.repos.d]# touch cloudera-manager.repo
[[email protected] yum.repos.d]# cat cloudera-manager.repo
[cloudera-manager]
name=Cloudera Manager
baseurl=http://archive.cloudera.com/cm5/redhat/6/x86_64/cm/5/
enabled=1
注意:
archive.cloudera.com是本地yum源的host
[[email protected] yum.repos.d]# yum list
第七步: (安裝postgresql服務)
[root@hadoop06 postgresql]# ls
總用量 6564
postgresql-8.4.18-1.el6_4.x86_64.rpm
postgresql-libs-8.4.18-1.el6_4.x86_64.rpm
postgresql-server-8.4.18-1.el6_4.x86_64.rpm
[root@hadoop06 postgresql]# rpm -ivh postgresql-libs-8.4.18-1.el6_4.x86_64.rpm
[root@hadoop06 postgresql]# rpm -ivh postgresql-8.4.18-1.el6_4.x86_64.rpm
[root@hadoop06 postgresql]# rpm -ivh postgresql-server-8.4.18-1.el6_4.x86_64.rpm
第八步: (配置Server服務)
[root@hadoop06 software]# chmod 777 cloudera-manager-installer.bin
[root@hadoop06 software]# ./cloudera-manager-installer.bin
注意:
如果使用該命令進行包安裝的情況下,報錯,出現異常,手動進行安裝配置的yum源
第九步: (關閉防火牆和Selinux服務)
[root@hadoop06 ~]# /etc/init.d/iptables stop
[root@hadoop06 ~]# chkconfig iptables off
[root@hadoop06 cdh5.11.0]# setenforce 0
修改/etc/selinux/config 檔案
將SELINUX=enforcing改為SELINUX=disabled
第十步: (啟動server服務程序)
[root@hadoop06 yum.repos.d]# /etc/init.d/cloudera-scm-server-db start
pg_ctl: server is running (PID: 1891)
/usr/bin/postgres "-D" "/var/lib/cloudera-scm-server-db/data"
[root@hadoop06 yum.repos.d]# /etc/init.d/cloudera-scm-server start
Starting cloudera-scm-server: [ OK ]
[root@hadoop06 software]# /etc/init.d/postgresql start
啟動 postgresql 服務: [確定]
<br>
等待大概兩分鐘,訪問 http://hadoop06:7180/ 進入管理端 (登陸名:admin 密碼:admin)
第十一步: 將cdh的parcel包放置到parcel-repo中
[[email protected] parcel-repo]# pwd
/opt/cloudera/parcel-repo
[[email protected] parcel-repo]# ll
total 1485360
-rw-r--r-- 1 root root 1520997979 Jun 13 2017 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel
-rw-r--r-- 1 root root 41 Jun 13 2017 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel.sha1
[[email protected] parcel-repo]# mv CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel.sha1 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel.sha
設定parcel包更新頻率
出現以torrent結尾的說明parcel包分配成功
[[email protected] parcel-repo]# ll
total 1485420
-rw-r--r-- 1 root root 1520997979 Jun 13 2017 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel
-rw-r--r-- 1 root root 41 Jun 13 2017 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel.sha
-rw-r----- 1 cloudera-scm cloudera-scm 58207 Feb 6 15:50 CDH-5.11.0-1.cdh5.11.0.p0.34-el6.parcel.torrent
第十二步: (部署服務)
注意:
1、出現CDH-5.11.0-1.cdh5.11.0.p0.34說明成功
2、parcel包放到必須在postgresql初始化完成後才能放入,否則不會顯示
注意:
1、必須是http服務
2、自定義的yum倉庫
3、清除快取
[[email protected] yum.repos.d]# yum clean all
4、檢視repo檔案
[[email protected] yum.repos.d]# ll
total 12
-rw-r--r-- 1 root root 675 Feb 6 10:51 CentOS-Base.repo
-rw-r--r-- 1 root root 129 Feb 6 16:05 cloudera-manager.repo
-rw-r--r-- 1 root root 230 Feb 6 10:51 epel.repo
[cloudera-manager]
name = Cloudera Manager, Version 5.11.0
baseurl = http://172.16.29.195/cm5/redhat/6/x86_64/cm/5/
gpgcheck = 0
#### 檢視是否能ping通
[[email protected] yum.repos.d]# ping 172.16.29.195
PING 47.97.113.34 (47.97.113.34) 56(84) bytes of data.
^C
--- 47.97.113.34 ping statistics ---
2 packets transmitted, 0 received, 100% packet loss, time 1058ms
5、報錯
Dependencies Resolved
=====================================================================================================================================
Package Arch Version Repository Size
=====================================================================================================================================
Installing:
cloudera-manager-agent x86_64 5.11.0-1.cm5110.p0.101.el6 cloudera-manager 9.1 M
Installing for dependencies:
cloudera-manager-daemons x86_64 5.11.0-1.cm5110.p0.101.el6 cloudera-manager 635 M
Transaction Summary
=====================================================================================================================================
Install 2 Package(s)
Total download size: 644 M
Installed size: 859 M
Downloading Packages:
(1/2): cloudera-manager-agent-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm | 9.1 MB 00:00
(2/2): cloudera-manager-daemons-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm | 635 MB 00:15
-------------------------------------------------------------------------------------------------------------------------------------
Total 42 MB/s | 644 MB 00:15
warning: rpmts_HdrFromFdno: Header V4 DSA/SHA1 Signature, key ID e8f86acd: NOKEY
Public key for cloudera-manager-daemons-5.11.0-1.cm5110.p0.101.el6.x86_64.rpm is not installed
解決方案:
1、手動安裝agent和daemon服務
2、開啟gpgcheck=0
[[email protected] yum.repos.d]# cat cloudera-manager.repo
[cloudera-manager]
name = Cloudera Manager, Version 5.11.0
baseurl = http://hadoop1/cm5/redhat/6/x86_64/cm/5/
enabled = 1
gpgcheck = 0
3、手動啟動agent服務
[[email protected] yum.repos.d]# /etc/init.d/cloudera-scm-agent start
Starting cloudera-scm-agent: [ OK ]