CDH5.X完全解除安裝步驟
1. 關閉叢集中的所有服務。
這個可以通過clouder manger 主頁關閉叢集。
2. 解除安裝
[[email protected] ~]# /usr/share/cmf/uninstall-cloudera-manager.sh
[[email protected] ~]# service cloudera-scm-agent stop
[[email protected] ~]# service cloudera-scm-agent stop
一下都是所有要解除安裝的叢集均要執行清除工作:
[[email protected] ~]# umount /var/run/cloudera-scm-agent/process
[[email protected] ~]# umount /var/run/cloudera-scm-agent/process
[[email protected] ~]# umount /var/run/cloudera-scm-agent/process
[[email protected] ~]# rm -rf /usr/share/cmf /var/lib/cloudera* /var/cache/yum/x86_64/6/cloudera* /var/log/cloudera* /var/run/cloudera* /etc/cloudera*
3. 解除安裝安裝包:
[[email protected] ~]# for f in `rpm -qa | grep cloudera ` ; do rpm -e ${f} ; done (如果有儲存,在執行一遍)
4. 清除安裝檔案
rm -rf /var/lib/hadoop-* /var/lib/impala /var/lib/solr /var/lib/zookeeper /var/lib/hue /var/lib/oozie /var/lib/pgsql /var/lib/sqoop2 /data/dfs/ /data/impala/ /data/yarn/ /dfs/ /impala/ /yarn/ /var/run/hadoop-*/ /var/run/hdfs-*/ /usr/bin/hadoop* /usr/bin/zookeeper* /usr/bin/hbase* /usr/bin/hive* /usr/bin/hdfs /usr/bin/mapred /usr/bin/yarn /usr/bin/sqoop* /usr/bin/oozie /etc/hadoop* /etc/zookeeper* /etc/hive* /etc/hue /etc/impala /etc/sqoop* /etc/oozie /etc/hbase* /etc/hcatalog
//只刪除hadoop系列的,不要刪除其他軟體的,否則其他軟體的版本控制會被破壞
[[email protected] alternatives]# rm -rf ` find /var/lib/alternatives/* ! -name "mta" ! -name "print" ! -name "zlibrary-ui" -mtime -3`
[[email protected] alternatives]# rm -rf /etc/alternatives/*
5. 殺死相關程序:
for u in hdfs mapred cloudera-scm hbase hue zookeeper oozie hive impala flume; do sudo kill $(ps -u $u -o pid=); done
6. 刪除parcel包分發檔案和解壓檔案
rm -rf /opt/cloudera/parcel-cache /opt/cloudera/parcels
到此解除安裝完畢。