HDP2.2 升級手冊
* 注意事項:
- 升級描述:當前HDP版本2.2.0.0,升級版本2.2.6.0;
- 手動升級(命令行)方式官方文檔:
http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.2.6/bk_upgrading_hdp_manually/content/ch_upgrade_2_1.html
1. 升級前准備工作
1.1 重啟服務* 注:因為上次升級Ambari metrics沒有重啟服務,所以這次重啟所有服務以應用上一次的配置更新;
1.2 備份所有服務的配置文件:
mkdir /root/backup tar -cvf /root/backup/hdp_config_backup.tar /etc/
1.3 檢查 Hive Server
節點端口使用情況,如果端口被占用,需要手動修改;
netstat -anp | grep 1001[01]
1.4 備份 Hive 元數據庫
:
備份 mysqldump hive > /root/backup/backup_hive.sql 還原 mysql hive < /root/backup/backup_hive.sql
1.5 關閉正在運行的 Mapreduce
、crontab 定時任務
、Kill掉所有已經發布的 Storm topology
;
1.6 將升級安裝包解壓到YUM主機。
tar -xzvf HDP-2.2.6.0-centos6-rpm.tar.gz mv HDP /var/www/html/HDP2.2.6
2. 升級
2.1 登錄到
Ambari
,添加新的HDP版本;
http://public-repo-1.hortonworks.com/HDP2.2.6/centos6/2.x/updates/2.2.6.0/ http://public-repo-1.hortonworks.com/HDP-UTILS-1.1.0.20/repos/centos6
2.2 保存后,點擊安裝,
Ambari
將為所有節點安裝新的HDP組件;
2.3 等待安裝后,點擊更新,
Ambari
將為所有節點更新HDP組件;
2.4 更新過程中,
Ambari
將提示6次需要干預的操作,因為升級前已經准備好了,所以當遇到提示時直接確認即可,整個升級過程將持續1小時左右;
升級完成
3. 恢復應用服務
3.1 升級完成后,
Hive server thrift
端口將改為10010
,所以需要檢查相關應用的配置,修改對應的端口參數值;
4. 其他
HDP 升級過程中的提示
Before continuing, please backup the Hive Metastore database located on the following host(s): hadoop002.icccuat.com.
The initial batch of DataNode, RegionServer and NodeManager hosts have been upgraded. You are advised to check the hosts and perform cluster/workload-specific tests against your cluster to ensure proper operation before proceeding with upgrade of the remaining services.
Please note that the HiveServer port will now change to 10010 if hive is using a binary transfer mode or 10011 if hive is using an http transport mode. You can use “netstat -anp | grep 1001[01]” to determine if the port is available on each of following HiveServer host(s): hadoop002.icccuat.com. If the port is not available, the process using it must be terminated.
Updated ‘hive-site’ with ‘hive.server2.thrift.port=10010’Before continuing, please deactivate and kill any currently running topologies.
Please rebuild your topology using the new Storm version dependencies and resubmit it using the newly created jar.
Your cluster version has been upgraded. Click on Finalize when you are ready to finalize the upgrade and commit to the new version. You are strongly encouraged to run tests on your cluster to ensure it is fully operational before finalizing. You cannot go back to the original version once the upgrade is finalized.