我正在尝试使用Ambari 1.7.0设置6节点HDP 2.2集群。受到黑客攻击(通过将“export PYTHON = / usr / bin / python2.6”添加到ambari-agent / ambari-enh)以使ambari-agent守护程序在代理节点上运行之后,我能够注册目标主机。
但是,在“部署”步骤中,我遇到了一个可怕的问题。看来,尽管我选择了HDP 2.2堆栈,但仍选择了HDP 2.0.6。
Traceback (most recent call last):
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/services/HDFS/package/scripts/datanode.py", line 21, in <module>
from hdfs_datanode import datanode
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/services/HDFS/package/scripts/hdfs_datanode.py", line 21, in <module>
from resource_management.libraries.functions.dfs_datanode_helper import handle_dfs_data_dir
ImportError: No module named dfs_datanode_helper
ambari-agent.log包含以下内容:
INFO 2015-02-06 00:11:47,707 PythonExecutor.py:118 - Result:
{'structuredOut': {},
'stdout': '2015-02-06 00:11:47,687 - Error while executing command
\'status\':\nTraceback (most recent call last):\n
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py",
line 123, in execute\n File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/services/GANGLIA/package/scripts/ganglia_monitor.py",
line 63, in status\n
raise ComponentIsNotRunning()\nComponentIsNotRunning',
'stderr': '2015-02-06 00:11:47,687 - Error while executing command
\'status\':\nTraceback (most recent call last):\n
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py",
line 123, in execute\n File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/services/GANGLIA/package/scripts/ganglia_monitor.py", line 63, in status\n
raise ComponentIsNotRunning()\nComponentIsNotRunning', 'exitcode': 1}
问题:即使选择了HDP 2.2,为什么仍要安装HDP 2.0.6?
我的环境信息:
CentOS 6.6,HortonWorks Ambari 1.7.0,HDP-2.2,HDP-UTILS-1.1
回购:
HDP-2.2 HDP-UTILS-1.1.0.20更新-ambari-1.7.0 ambari-1.x
最佳答案
那是预期的行为。 Ambari Stacks可以继承以前的版本。因此,在您的情况下,对于Stack 2.2,HDFS继承自Stack版本2.1,而后者又继承自版本2.0.6。
在这里定义:https://github.com/apache/ambari/blob/release-1.7.0/ambari-server/src/main/resources/stacks/HDP/2.2/metainfo.xml
现在,回到真正的问题,Ganglia根本没有运行。您看到的错误是在Ganglia服务的状态检查中引发的。我将从这里开始。
关于python - HortonWorks Ambari 1.7.0选择错误的HDP堆栈,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/28358305/