- 操作系统:Gentoo、CentOS
- 版本:2.1.0
按照快速入门指南,运行时出现以下错误bootstrap-localcloud
:
cloudify@default> bootstrap-localcloud
STARTING CLOUDIFY MANAGEMENT
2012-05-30 14:55:50,396 WARNING [org.cloudifysource.shell.commands.AbstractGSCommand] - ; \
Caused by: org.cloudifysource.shell.commands.CLIException: \
Error while starting agent. \
Please make sure that another agent is not already running.
Operation failed.
Cloudify 使用哪个端口来检查代理是否正在运行?
PS:在 Windows 上运行时它工作正常。
更新:5 月 30 日星期三 22:37:30 ICT 2012
回复@tamirkorem 和@Itai Frenkel:
我很确定,因为这是我第一次在 2 台服务器上运行该命令。更清楚的是,这里是输出:
cloudify@default> teardown-localcloud
Teardown will uninstall all of the deployed services. Do you want to continue [y/n]?
2012-05-30 22:43:33,145 WARNING [org.cloudifysource.shell.commands.AbstractGSCommand] - Teardown failed. Failed to fetch the currently deployed applications list. For force teardown use the -force flag.
Operation failed.
cloudify@default> teardown-localcloud -force
Teardown will uninstall all of the deployed services. Do you want to continue [y/n]?
Failed to fetch the currently deployed applications list. Continuing teardown-localcloud.
.2012-05-30 22:46:39,040 WARNING [org.cloudifysource.shell.commands.AbstractGSCommand] - Teardown aborted, an agent was not found on the local machine.
Operation failed.
这是详细的结果:
cloudify@default> bootstrap-localcloud --verbose
NIC Address=127.0.0.1
Lookup Locators=127.0.0.1:4172
Lookup Groups=localcloud
Starting agent and management processes:
gs-agent.sh gsa.global.lus 0 gsa.lus 0 gsa.gsc 0 gsa.global.gsm 0 gsa.gsm_lus 1 gsa.global.esm 0 gsa.esm 1 >/dev/null 2>&1
STARTING CLOUDIFY MANAGEMENT
2012-05-30 22:36:12,870 WARNING [org.cloudifysource.shell.commands.AbstractGSCommand] - ; Caused by: org.cloudifysource.shell.commands.CLIException: Error while starting agent. Please make sure that another agent is not already running. Command executed: /usr/local/src/gigaspaces-cloudify-2.1.0-ga/bin/gs-agent.sh gsa.global.lus 0 gsa.lus 0 gsa.gsc 0 gsa.global.gsm 0 gsa.gsm_lus 1 gsa.global.esm 0 gsa.esm 1 >/dev/null 2>&1
回复@Eliran Malka:
在端口 4172 上没有这样的进程监听:
# netstat --protocol=inet -nlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:9050 0.0.0.0:* LISTEN 2363/tor
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 2331/mysqld
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 2293/cupsd
您可能已经在您的机器上运行了 localcloud。有几种选择:
connect localhost
teardown-localcloud
之前bootstrap-localcloud
有关更多调试信息,请使用该
--verbose
选项(例如bootstrap-localcloud --verbose
)发现了问题。
当我手动运行此命令时:
/usr/local/src/gigaspaces-cloudify-2.1.0-ga/bin/gs-agent.sh gsa.global.lus 0 gsa.lus 0 gsa.gsc 0 gsa.global.gsm 0 gsa.gsm_lus 1 gsa.global.esm 0 gsa.esm 1 > /var/log/cloudify.log 2>&1
(更改
/dev/null
为日志文件)我会在日志文件中看到类似这样的内容:
因此,正如我对 所做的那样
cloudify.sh
,我必须为这些 shell 脚本授予执行权限:现在工作正常:
Cloudify 开发人员应该检查执行权限并给我们一个明确的警告,而不是像上面那样过于模糊的消息。