Ambari2.5.3卸载smartsense
Ambari2.5.3卸载smartsense
启动后发现会有一个SmartSence服务,并且一直是启动不成功。查看错误显示 【Please configure a vaid SmartSense ID to proceed.】
SmartSence是 HORTONWORKS 公司的一款增值服务产品,为hadoop集群提供指导帮助,SmartSence是无法像Ambari其他服务一样安装的。
而这个SmartSenseID需要安装之后才会由官方提供。
具体安装参考 https://docs.hortonworks.com/HDPDocuments/SS1/SmartSense-1.1.0/bk_smartsense_admin/content/ch01s02s05s01.html
第一步,确定SmartSence服务均已关闭
1 curl -u admin:$PASSWORD -i -H 'X-Requested-By: ambari' -X PUT -d '{"RequestInfo": {"context" :"Stop SmartSense via REST"}, "Body": {"ServiceInfo": {"state": "INSTALLED"}}}' http://AMBARI_SERVER_HOST:8080/api/v1/clusters/CLUSTER_NAME/services/SMARTSENSE
第二步,卸载SmartSense组件
1 curl -u admin:$PASSWORD -i -H 'X-Requested-By: ambari' -X POST -d '{"RequestInfo": {"context" :"Uninstall SmartSense via REST", "command":"Uninstall"}, "Requests/resource_filters":[{"hosts":"comma separated host names", "service_name":"SMARTSENSE", "component_name":"HST_AGENT"}]}' http://AMBARI_SERVER_HOST:8080/api/v1/clusters/CLUSTER_NAME/requests
第三步,从Ambari中卸载掉SmartSense服务
1 curl -u admin:$PASSWORD -H 'X-Requested-By: ambari' -X DELETE http://AMBARI_SERVER_HOST:8080/api/v1/clusters/CLUSTER_NAME/services/SMARTSENSE
第四步,重起Ambari使更改生效
1 ambari-server restart
注释:admin为用户名,不用更改;¥PASSWORD为admin的密码,修改成自己admin的密码;AMBARI_SERVER_HOST是ambari-server所在主机的IP或者域名,要修改成自己ambari-server的;CLUSTER_NAME是ambari上安装的集群的名字,即要卸载哪个集群上的SmartSense就写哪个集群的名字。