原来的Lab Manager的环境整个Crash了,我们升级Lab Manager的时候没有做snapshot,重新搭建了整个环境,还好没有浪费什么时间。
原来搭建的自动deploy的环境出问题了,原来我安装的是sshwindows,都是好好的,现在我们换了一个server,美国那边的一个工程师已经安装了cygwin sshd作为ssh server,偷懒不想重新安装,结果不好使,因为很多sshexec失败,最奇怪的一个是:
<sshexec host="${remote.host}"
trust="yes"
username="${user}"
password="${password}"
command="net stop ${jboss.service.name}"/>
<waitfor maxwait="300" maxwaitunit="second" checkevery="2000">
<not>
<socket server="${remote.host}" port="${jboss.port}"/>
</not>
</waitfor>
<sshexec host="${remote.host}"
trust="yes"
username="${user}"
password="${password}"
command="net start ${jboss.service.name}"/>
第一个sshexec执行成功,第二个失败,两个命令唯一的区别就是一个是stop,一个是start,而且执行的时候控制台都是显示执行成功,最后第二个命令的返回值是-1导致build failed。
禁用原来的cygwin,问题解决,没有时间研究具体的差异了。
2009-3-19 更新:
有时候失败有时候成功,可能是service的问题,返回值不稳定。
sshwindows的问题是它完全不检查返回值,所以没有问题,相对而言,还是cygwin更好一些。
发表评论