You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brooklyn.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/04/25 16:33:04 UTC
[jira] [Commented] (BROOKLYN-484) JBoss7 entity restart fails
(launch ssh session returns before process running?)
[ https://issues.apache.org/jira/browse/BROOKLYN-484?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15983193#comment-15983193 ]
ASF GitHub Bot commented on BROOKLYN-484:
-----------------------------------------
GitHub user aledsage opened a pull request:
https://github.com/apache/brooklyn-library/pull/101
BROOKLYN-484: fix restart() - launch checks log file
See https://issues.apache.org/jira/browse/BROOKLYN-484
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/aledsage/brooklyn-library BROOKLYN-484
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/brooklyn-library/pull/101.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #101
----
commit 276156a2d1b83fe10c7ad0937f0d438847ab4e7e
Author: Aled Sage <al...@gmail.com>
Date: 2017-04-21T11:19:54Z
BROOKLYN-484: fix restart() - launch checks log file
commit ba1f2efec7e8bb5e9ba34fe2355576129ebd8e42
Author: Aled Sage <al...@gmail.com>
Date: 2017-04-25T16:22:26Z
jboss6.launch: wait for ‘Starting’
----
> JBoss7 entity restart fails (launch ssh session returns before process running?)
> --------------------------------------------------------------------------------
>
> Key: BROOKLYN-484
> URL: https://issues.apache.org/jira/browse/BROOKLYN-484
> Project: Brooklyn
> Issue Type: Bug
> Reporter: Aled Sage
> Priority: Minor
>
> With version 0.11.0-rc1...
> We've seen a failure of the {{restart}} effector for {{JBoss7Server}}. The post-launch step failed (waiting for the url to be reachable/responsive).
> Unfortunately there's no additional debugging information available - the VMs are gone, and the debug log is not available.
> However, I've identified a reason why this might happen.
> On {{start}}, the {{JBoss7SshDriver.launch}} script will redirect stdout/stderr to a file named {{console}}, and will then wait for that file to say 'starting'.
> Importantly, there is an old comment saying:
> {noformat}
> // We wait for evidence of JBoss running because, using SshCliTool,
> // we saw the ssh session return before the JBoss process was fully running
> // so the process failed to start.
> {noformat}
> On {{restart}}, it stops the process, and then calls {{JBoss7SshDriver.launch}} again. However, it appends to the file {{console}}. Therefore when it checks if the file says 'starting' it will return immediately. This means the ssh session could return before the JBoss process was fully running.
> A solution would be to change launch, to first move the previous {{console}} file. This would mean the subsequent calls to the {{launch}} script would wait for the process to be running.
> This same problem would also apply to other entities, such as {{TomcatSshDriver.launch}}.
> A way to reproduce this would probably be to repeatedly call the {{restart}} effector (waiting for serviceUp to be true again between each). It almost always works - I've personally only seen this failure once.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)