我是一个从apache学习Hadoop的新人,我一直试图在我的Ubuntu VirtualBox环境中安装ambari,但是,遇到这个问题我很累。
首先,系统提醒我" Ambari Server' start'成功完成"如下
~# ambari-server start
Using python /usr/bin/python2.7
Starting ambari-server
Ambari Server running with administrator privileges.
Organizing resource files at /var/lib/ambari-server/resources...
Server PID at: /var/run/ambari-server/ambari-server.pid
Server out at: /var/log/ambari-server/ambari-server.out
Server log at: /var/log/ambari-server/ambari-server.log
Waiting for server start...................
Ambari Server 'start' completed successfully.
但是,我无法通过" http://127.0.0.1:8080"访问ambari服务,当我检查服务器状态如下
~# ambari-server status
Using python /usr/bin/python2.7
Ambari-server status
Ambari Server not running. Stale PID File at: /var/run/ambari-server/ambari-server.pid
当我检查/var/run/ambari-server/ambari-server.pid的文件时
~# cat /var/run/ambari-server/ambari-server.pid
2875
当我检查日志文件时,它带有以下行
22 May 2015 10:59:42,876 INFO [main] Configuration:527 - Reading password from existing file
22 May 2015 10:59:43,073 INFO [main] Configuration:747 - Hosts Mapping File null
22 May 2015 10:59:43,074 INFO [main] HostsMap:60 - Using hostsmap file null
22 May 2015 10:59:45,169 INFO [main] ControllerModule:172 - Detected MYSQL as the database type from the JDBC URL
22 May 2015 10:59:45,253 INFO [main] ControllerModule:214 - Using c3p0 ComboPooledDataSource as the EclipsLink DataSource
22 May 2015 10:59:45,416 INFO [main] MLog:80 - MLog clients using log4j logging.
22 May 2015 10:59:46,124 INFO [main] C3P0Registry:204 - Initializing c3p0-0.9.1.1 [built 15-March-2007 01:32:31; debug? true; trace: 10]
22 May 2015 10:59:59,830 ERROR [main] DBAccessorImpl:99 - Error while creating database accessor
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
我搜索了互联网,但没有找到解决这个问题的方法。
顺便说一下,我还没有安装Hadoop,不管这是不是问题?
提前致谢。
答案 0 :(得分:0)
我希望这与https://issues.apache.org/jira/browse/AMBARI-9215
有关当我登录服务器然后启动Ambari时,它可以工作。但是当我开始使用面料时,它无法正常工作。
答案 1 :(得分:0)
作为一种解决方法,我试图将脚本推送到目标主机并在后台执行命令。
/root/scripts/Start_Ambari.sh的内容低于内容。
ambari-server start&
答案 2 :(得分:0)
最后它起作用了
我使用nohup
而不是在后台运行命令。有效。
在远程机器中执行的脚本内容如下所示。
#!/bin/bash
nohup ambari-server start
答案 3 :(得分:0)
对于这种情况,问题可能是任何问题。让我指出其中的一些,无论哪个有用,请告诉我们。
以root身份运行ambari-server
$ sudo ambari-server start
检查您的{{1}}文件
检查您的8080端口是否已打开以进行访问。