Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id E4613200C7E for ; Tue, 23 May 2017 15:57:12 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id E31E2160BD3; Tue, 23 May 2017 13:57:12 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 36475160BB6 for ; Tue, 23 May 2017 15:57:12 +0200 (CEST) Received: (qmail 28568 invoked by uid 500); 23 May 2017 13:57:11 -0000 Mailing-List: contact dev-help@brooklyn.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@brooklyn.apache.org Delivered-To: mailing list dev@brooklyn.apache.org Received: (qmail 28548 invoked by uid 99); 23 May 2017 13:57:11 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 23 May 2017 13:57:11 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id D602FCEF9B for ; Tue, 23 May 2017 13:57:10 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.201 X-Spam-Level: X-Spam-Status: No, score=-99.201 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id M2FtWvu7lEtE for ; Tue, 23 May 2017 13:57:10 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 26F1C5FD38 for ; Tue, 23 May 2017 13:57:10 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 96C26E005B for ; Tue, 23 May 2017 13:57:09 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 4FEF421B57 for ; Tue, 23 May 2017 13:57:04 +0000 (UTC) Date: Tue, 23 May 2017 13:57:04 +0000 (UTC) From: "Aled Sage (JIRA)" To: dev@brooklyn.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (BROOKLYN-484) JBoss7 entity restart fails (launch ssh session returns before process running?) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Tue, 23 May 2017 13:57:13 -0000 [ https://issues.apache.org/jira/browse/BROOKLYN-484?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Aled Sage resolved BROOKLYN-484. -------------------------------- Resolution: Fixed Fix Version/s: 0.12.0 Fixed in https://github.com/apache/brooklyn-library/pull/101 > 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 > Fix For: 0.12.0 > > > 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)