Bug 960741 - JBoss init scripts time out when using full profiles.
Summary: JBoss init scripts time out when using full profiles.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Scripts and Commands
Version: 6.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ER2
: EAP 6.4.0
Assignee: Permaine Cheung
QA Contact: Katerina Odabasi
URL:
Whiteboard:
Depends On:
Blocks: 1183501
TreeView+ depends on / blocked
 
Reported: 2013-05-07 20:31 UTC by Eric Rich
Modified: 2019-08-19 12:45 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1183501 (view as bug list)
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1183501 0 unspecified CLOSED [GSS](6.4.z) JBoss init scripts time out when using full profiles (zip) 2021-02-22 00:41:40 UTC

Internal Links: 1183501

Description Eric Rich 2013-05-07 20:31:52 UTC
Description of problem:

When using the standalone-full-ha.xml profile or removes the console logger from their profile they will experience a timeout bug when starting their server.

#from /etc/init.d/jbossas
 until [ $count -gt $JBOSS_STARTUP_WAIT ]
    do
      grep -q 'JBoss EAP 6.*started in' $JBOSS_CONSOLE_LOG > /dev/null 2>&1
      if [ $? -eq 0 ] ; then
        launched=true
        success "${NAME} startup"
        echo
        break
      fi
      sleep 10
      let count=$count+10;
    done


How reproducible:

Set or alter the JBoss init script to use 'standalone-full-ha.xml'

     JBOSS_SERVER_CONFIG=${JBOSS_SERVER_CONFIG:-""}
                                                 ^ Add it here. 
or export JBOSS_SERVER_CONFIG='standalone-full-ha.xml' in your /etc/jbossas/jbossas.conf file

  
Actual results:

Start up times out, because its looking for 'JBoss EAP 6.*started in' in the console log. 

Solution: 

Ensure that the following in in your configuration:

           <root-logger>
                <level name="INFO"/>
                <handlers>
                    <handler name="CONSOLE"/> <!--FIXME: This Line-->
                    <handler name="FILE"/>
                </handlers>
            </root-logger>

This may be a clone of https://bugzilla.redhat.com/show_bug.cgi?id=900663

Comment 1 Fernando Nasser 2013-05-07 20:37:34 UTC
Changed the component to Server.  This is a problem in the provided sample configuration file (or it is a plain duplicate of 900663).  You just happened to be using a RPM installation.

Comment 2 Eric Rich 2013-05-07 20:55:16 UTC
The issue seems to be with the provided configuration file. However I feel that this issue may be a duplicate of 900663 but would like for engineering to confirm. 

The BZ's are technically different however they may be two solutions to the same problem.

Comment 8 Permaine Cheung 2015-01-05 19:25:11 UTC
I tried using the current init script (from EAP 6.3.2) with JBOSS_SERVER_CONFIG set to "standalone-full-ha.xml", it starts and stops without any issue, marking this as MODIFIED. Please reopen if there are further issue.

Comment 9 Petr Kremensky 2015-01-15 12:38:01 UTC
I cannot speak for RPM distribution, but this is still an issue for jboss-as-standalone.sh inside zip distribution.

Scripts is still searching the console log which is not available (comment 7).
...
  until [ $count -gt $STARTUP_WAIT ]
  do
    grep 'JBAS015874:' $JBOSS_CONSOLE_LOG > /dev/null
    if [ $? -eq 0 ] ; then
      launched=true
      break
    fi
    sleep 1
    let count=$count+1;
  done
...

Just add the following line into jboss-as.conf file to reproduce.
JBOSS_CONFIG=standalone-full-ha.xml

Comment 10 Permaine Cheung 2015-01-15 13:57:20 UTC
This BZ was reported specifically against the init scripts in the RPM, for the issue you find with jboss-as-standalone.sh, please file a separate BZ against the scripts that are part of the zip and are maintained upstream so that we can keep this one for the init script. Thanks.

Comment 11 Katerina Odabasi 2015-01-19 08:12:20 UTC
No RPMs delivered with EAP 6.4.0.ER1 build. Postponing verification to ER2.

Comment 13 Katerina Odabasi 2015-02-25 12:05:20 UTC
Verified in RPM installation of EAP 6.4.0.ER2.

Comment 14 Numera SPA 2017-09-20 08:39:11 UTC
(In reply to Petr Kremensky from comment #9)
> I cannot speak for RPM distribution, but this is still an issue for
> jboss-as-standalone.sh inside zip distribution.
> 
> Scripts is still searching the console log which is not available (comment
> 7).
> ...
>   until [ $count -gt $STARTUP_WAIT ]
>   do
>     grep 'JBAS015874:' $JBOSS_CONSOLE_LOG > /dev/null
>     if [ $? -eq 0 ] ; then
>       launched=true
>       break
>     fi
>     sleep 1
>     let count=$count+1;
>   done
> ...
> 
> Just add the following line into jboss-as.conf file to reproduce.
> JBOSS_CONFIG=standalone-full-ha.xml

Hi, hope this could help:

I had to modify standalone-full-ha.xml adding these lines:

1) ADD console-handler CONSOLE
...
  <profile>
        <subsystem xmlns="urn:jboss:domain:logging:1.4">
            <console-handler name="CONSOLE">
                <level name="INFO"/>
                <formatter>
                    <named-formatter name="COLOR-PATTERN"/>
                </formatter>
            </console-handler>
...

2) ADD the handler CONSOLE and the FORMATTER COLOR-NAME
... 
<root-logger>
                <level name="INFO"/>
                <handlers>
                    <handler name="CONSOLE"/>
                    <handler name="FILE"/>
                </handlers>
            </root-logger>
            <formatter name="PATTERN">
                <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
            </formatter>
            <formatter name="COLOR-PATTERN">
                <pattern-formatter pattern="%K{level}%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
            </formatter>
...

Regards


Note You need to log in before you can comment on or make changes to this bug.