Bug 777711 (SOA-227) - Need to add -D java.awt.headless=true to jboss-soa-p.4.2.0/jboss-as/bin/jboss_init_redhat.sh - without this - server can abort
Summary: Need to add -D java.awt.headless=true to jboss-soa-p.4.2.0/jboss-as/bin/jbos...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: SOA-227
Product: JBoss Enterprise SOA Platform 4
Classification: JBoss
Component: Tooling
Version: 4.2 IR8
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.2 CR2
Assignee: trev
QA Contact:
URL: http://jira.jboss.org/jira/browse/SOA...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-12-11 20:39 UTC by Len DiMaggio
Modified: 2008-10-08 15:39 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
soa-4.2.0-IR8.0.zip
Last Closed: 2008-02-04 18:31:36 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 778416 0 high CLOSED groovy_gateway quickstart fails on deploy 2021-02-22 00:41:40 UTC
Red Hat Bugzilla 778423 0 high CLOSED Default configuration (run -c default) should not be headless 2021-02-22 00:41:40 UTC
Red Hat Issue Tracker SOA-227 0 Minor Closed Need to add -D java.awt.headless=true to jboss-soa-p.4.2.0/jboss-as/bin/jboss_init_redhat.sh - without this - server ca... 2014-04-07 22:22:14 UTC

Internal Links: 778416 778423

Description Len DiMaggio 2007-12-11 20:39:48 UTC
Date of First Response: 2007-12-13 14:46:32
project_key: SOA

Description of problem:
Need to add  -D java.awt.headless=true to jboss-soa-p.4.2.0/jboss-as/bin/jboss_init_redhat.sh - without this - server can be aborted

The problem is that the HSQL Database Manager does not start if the server is stated as a Linux service - as there is no head to which the AWT display can be directed. This problem was first reported in JBPAPP-180.

Version-Release number of selected component (IR or RC #, component ver)
soa-4.2.0-IR8.0.zip

How reproducible:
100%

Steps to Reproduce: 
1.Startup the linux service, attempt to invoke the DatabaseManager

Actual results:

For SOA-P IR8 - one of two different results can happen.

1) If the service is started via /sbin/service <service name> start, this error is correctly written to the server log:

2007-12-11 14:53:49,368 ERROR [org.jboss.jdbc.HypersonicDatabase] Failed to start database manager because this is a headless configuration (no display, mouse or keyword)

2) But - If the service is started from the CLI with jboss-soa-p.4.2.0/jboss-as/bin/jboss_init_redhat.sh start - this error is displayed and the server aborts

X11 connection rejected because of wrong authentication.

Expected results:

This error should be logged - the server should not abort.

ERROR [org.jboss.jdbc.HypersonicDatabase] Failed to start database manager because this is a headless configuration (no display, mouse or keyword)

Additional information:

Adding this to jboss-soa-p.4.2.0/jboss-as/bin/jboss_init_redhat.sh seems to stop the server from aborting:

JAVA_OPTS="$JAVA_OPTS -D java.awt.headless=true"
.
.
.
JBOSS_CMD_START="cd $JBOSS_HOME/bin; $JBOSSSH $JAVA_OPTS"

Comment 1 Len DiMaggio 2007-12-11 20:40:02 UTC
Link: Added: This issue is related to JBPAPP-180


Comment 2 Mike Brock 2007-12-13 19:46:32 UTC
Trevor, if you're going to be patching the startup script to fix the default profile issue, it probably makes sense for you to take this JIRA and do it at the same time.

Comment 3 Len DiMaggio 2007-12-20 17:43:58 UTC
This problem is still present in the beta 1 build.

Comment 5 Len DiMaggio 2008-01-21 03:23:38 UTC
This problem is still present - but in a less serious form.

The server no longer aborts.

But - it does allow the Hypersonic DB manager app GUI to be displayed - even those headless is set to true:

[ldimaggi@ldimaggi bin]$ grep headless *
jboss_init_redhat.sh:# set headless as true to stop HSQL Database Manager failure if running as linux service.
jboss_init_redhat.sh:JAVA_OPTS="$JAVA_OPTS -D java.awt.headless=true"

Oh - here's the problem - this:

JAVA_OPTS="$JAVA_OPTS -D java.awt.headless=true"
JBOSS_CMD_START="cd $JBOSS_HOME/bin $JAVA_OPTS; $JBOSSSH"
JBOSS_CMD_STOP=${JBOSS_CMD_STOP:-"java -classpath $JBOSSCP org.jboss.Shutdown --shutdown"}

should be:

JAVA_OPTS="$JAVA_OPTS -D java.awt.headless=true"
JBOSS_CMD_START="cd $JBOSS_HOME/bin; $JBOSSSH $JAVA_OPTS"
JBOSS_CMD_STOP=${JBOSS_CMD_STOP:-"java -classpath $JBOSSCP org.jboss.Shutdown --shutdown"}




Comment 6 Len DiMaggio 2008-01-23 20:16:29 UTC
New problem with jboss_init_redhat.sh in the RC1 build:

Syntax error on line 64. 

   This:      JBOSS_CMD_START="cd $JBOSS_HOME/bin; $JBOSSSH" $JAVA_OPTS
   Should be: JBOSS_CMD_START="cd $JBOSS_HOME/bin; $JBOSSSH $JAVA_OPTS"

(look for the trailing ")


Comment 7 trev 2008-01-24 12:47:15 UTC
svn version 848 - line is now

JBOSS_CMD_START="cd $JBOSS_HOME/bin; $JBOSSSH $JAVA_OPTS"

Comment 8 Len DiMaggio 2008-02-04 18:31:36 UTC
Verified in CR2 build.

Comment 9 Kevin Conner 2008-10-01 08:34:48 UTC
Link: Added: This issue related SOA-900


Comment 10 Len DiMaggio 2008-10-08 15:39:51 UTC
Link: Added: This issue related SOA-906



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