gpt4 book ai didi

python - 安装cloudera管理代理时,出现No module named cmf.alternatives错误

转载 作者:太空宇宙 更新时间:2023-11-03 18:08:03 25 4
gpt4 key购买 nike

我是第一次安装cloudera集群。

在集群安装页面上,显示一些消息,例如:

Installation failed. Failed to receive heartbeat from agent.

Ensure that the host's hostname is configured properly.

Ensure that port 7182 is accessible on the Cloudera Manager server (check firewall rules).

Ensure that ports 9000 and 9001 are free on the host being added.

Check agent logs in /var/log/cloudera-scm-agent/ on the host being added (some of the logs can be found in the installation details).

然后在日志文件中,我发现:

[21/Oct/2014 05:29:54 +0000] 9155 MainThread agent ERROR Failed to connect to previous supervisor.
.....

SystemExit: 2

在/var/log/cloudera-scm-agent/cloudera-scm-agent.out 文件中,我发现:

[21/Oct/2014 11:29:15 +0000] 1658 MainThread agent        INFO     Logging to /var/log/cloudera-scm-agent/cloudera-scm-agent.log
Error: could not find config file /var/run/cloudera-scm-agent/supervisor/supervisord.conf
For help, use /usr/lib64/cmf/agent/src/cmf/agent.py -h

....

Session terminated, killing shell... ...killed.

我运行:/usr/lib64/cmf/agent/src/cmf/agent.py -h

系统告诉我:

/usr/lib64/cmf/agent/src/cmf/agent.py:24: DeprecationWarning: the sha module is deprecated; use the hashlib module instead

import sha

Traceback (most recent call last):

File "/usr/lib64/cmf/agent/src/cmf/agent.py", line 40, in <module>

import cmf.alternatives

ImportError: No module named cmf.alternatives

我的ENV是: centos 6.5,Python 2.6.6,Cloudera管理服务器是5.2

所以,我想知道将安装哪个模块来修复此错误。

或者如何配置在安装中使用 cmf 模块?

在哪里可以找到描述 Cloudera 的 Python 的文档?
非常感谢。

最佳答案

您好,您可以按照说明操作,将 sha 替换为 hashlib,然后重试。

...
# import sha
import hashlib

# and use hashlib.sha1 instead of sha.sha in the following code
hashlib.sha1(...)
...

关于python - 安装cloudera管理代理时,出现No module named cmf.alternatives错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26480566/

25 4 0