Ambari 2.0 安装失败,“<urlopen error [Errno 111] Connection refused>”
Ambari 2.0 installation fails, "<urlopen error [Errno 111] Connection refused>"
正在尝试通过Ambari 2.0 建立Hadoop 集群,但是在安装阶段失败。以下是其中一个数据节点的故障日志:
stderr: /var/lib/ambari-agent/data/errors-416.txt
Traceback (most recent call last):
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 34, in <module>
BeforeAnyHook().execute()
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 214, in execute
method(env)
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 29, in hook
setup_jce()
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py", line 40, in setup_jce
content = DownloadSource(format("{jce_location}/{jce_policy_zip}")),
File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 148, in __init__
self.env.run()
File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 152, in run
self.run_action(resource, action)
File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 118, in run_action
provider_action()
File "/usr/lib/python2.6/site-packages/resource_management/core/providers/system.py", line 108, in action_create
content = self._get_content()
File "/usr/lib/python2.6/site-packages/resource_management/core/providers/system.py", line 150, in _get_content
return content()
File "/usr/lib/python2.6/site-packages/resource_management/core/source.py", line 50, in __call__
return self.get_content()
File "/usr/lib/python2.6/site-packages/resource_management/core/source.py", line 181, in get_content
web_file = opener.open(req)
File "/usr/lib64/python2.6/urllib2.py", line 391, in open
response = self._open(req, data)
File "/usr/lib64/python2.6/urllib2.py", line 409, in _open
'_open', req)
File "/usr/lib64/python2.6/urllib2.py", line 369, in _call_chain
result = func(*args)
File "/usr/lib64/python2.6/urllib2.py", line 1190, in http_open
return self.do_open(httplib.HTTPConnection, req)
File "/usr/lib64/python2.6/urllib2.py", line 1165, in do_open
raise URLError(err)
urllib2.URLError: <urlopen error [Errno 111] Connection refused>
Error: Error: Unable to run the custom hook script ['/usr/bin/python2.6', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-416.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-416.json', 'INFO', '/var/lib/ambari-agent/data/tmp']
stdout: /var/lib/ambari-agent/data/output-416.txt
2015-05-12 14:46:24,028 - u"Directory['/var/lib/ambari-agent/data/tmp/AMBARI-artifacts/']" {'recursive': True}
2015-05-12 14:46:24,233 - u"File['/var/lib/ambari-agent/data/tmp/AMBARI-artifacts//UnlimitedJCEPolicyJDK7.zip']" {'content': DownloadSource('http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip')}
2015-05-12 14:46:24,323 - Downloading the file from http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip
Error: Error: Unable to run the custom hook script ['/usr/bin/python2.6', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-416.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-416.json', 'INFO', '/var/lib/ambari-agent/data/tmp']
我认为问题出在这里:
2015-05-12 16:21:44,698 - Downloading the file from http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip
它试图从本地主机下载,但我认为它应该是名称节点的地址。我错过了什么吗?
在 ambari 服务器及其所有客户端节点上使用 FQHN(完全限定主机名)。
正在尝试通过Ambari 2.0 建立Hadoop 集群,但是在安装阶段失败。以下是其中一个数据节点的故障日志:
stderr: /var/lib/ambari-agent/data/errors-416.txt
Traceback (most recent call last):
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 34, in <module>
BeforeAnyHook().execute()
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 214, in execute
method(env)
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 29, in hook
setup_jce()
File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py", line 40, in setup_jce
content = DownloadSource(format("{jce_location}/{jce_policy_zip}")),
File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 148, in __init__
self.env.run()
File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 152, in run
self.run_action(resource, action)
File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 118, in run_action
provider_action()
File "/usr/lib/python2.6/site-packages/resource_management/core/providers/system.py", line 108, in action_create
content = self._get_content()
File "/usr/lib/python2.6/site-packages/resource_management/core/providers/system.py", line 150, in _get_content
return content()
File "/usr/lib/python2.6/site-packages/resource_management/core/source.py", line 50, in __call__
return self.get_content()
File "/usr/lib/python2.6/site-packages/resource_management/core/source.py", line 181, in get_content
web_file = opener.open(req)
File "/usr/lib64/python2.6/urllib2.py", line 391, in open
response = self._open(req, data)
File "/usr/lib64/python2.6/urllib2.py", line 409, in _open
'_open', req)
File "/usr/lib64/python2.6/urllib2.py", line 369, in _call_chain
result = func(*args)
File "/usr/lib64/python2.6/urllib2.py", line 1190, in http_open
return self.do_open(httplib.HTTPConnection, req)
File "/usr/lib64/python2.6/urllib2.py", line 1165, in do_open
raise URLError(err)
urllib2.URLError: <urlopen error [Errno 111] Connection refused>
Error: Error: Unable to run the custom hook script ['/usr/bin/python2.6', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-416.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-416.json', 'INFO', '/var/lib/ambari-agent/data/tmp']
stdout: /var/lib/ambari-agent/data/output-416.txt
2015-05-12 14:46:24,028 - u"Directory['/var/lib/ambari-agent/data/tmp/AMBARI-artifacts/']" {'recursive': True}
2015-05-12 14:46:24,233 - u"File['/var/lib/ambari-agent/data/tmp/AMBARI-artifacts//UnlimitedJCEPolicyJDK7.zip']" {'content': DownloadSource('http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip')}
2015-05-12 14:46:24,323 - Downloading the file from http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip
Error: Error: Unable to run the custom hook script ['/usr/bin/python2.6', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-416.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-416.json', 'INFO', '/var/lib/ambari-agent/data/tmp']
我认为问题出在这里:
2015-05-12 16:21:44,698 - Downloading the file from http://localhost:8080/resources//UnlimitedJCEPolicyJDK7.zip
它试图从本地主机下载,但我认为它应该是名称节点的地址。我错过了什么吗?
在 ambari 服务器及其所有客户端节点上使用 FQHN(完全限定主机名)。