Return-Path: X-Original-To: apmail-geronimo-dev-archive@www.apache.org Delivered-To: apmail-geronimo-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0F8909D97 for ; Fri, 17 Feb 2012 21:07:22 +0000 (UTC) Received: (qmail 96759 invoked by uid 500); 17 Feb 2012 21:07:21 -0000 Delivered-To: apmail-geronimo-dev-archive@geronimo.apache.org Received: (qmail 96691 invoked by uid 500); 17 Feb 2012 21:07:21 -0000 Mailing-List: contact dev-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list dev@geronimo.apache.org Received: (qmail 96680 invoked by uid 99); 17 Feb 2012 21:07:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 17 Feb 2012 21:07:21 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 17 Feb 2012 21:07:18 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 6DA1F1BD801 for ; Fri, 17 Feb 2012 21:06:57 +0000 (UTC) Date: Fri, 17 Feb 2012 21:06:57 +0000 (UTC) From: "Russell E Glaue (Commented) (JIRA)" To: dev@geronimo.apache.org Message-ID: <2046257552.52128.1329512817450.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <503387106.147.1317070932640.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (GERONIMO-6174) Environment variables being set in bin/geronimo does not account for named server instances MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/GERONIMO-6174?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13210566#comment-13210566 ] Russell E Glaue commented on GERONIMO-6174: ------------------------------------------- This issue is partially resolved by the introduction of the GERONIMO_SERVER shell variable with patch in GERONIMO-6275. With this patch, java properties are being configured on startup in regards to the existence of a server instance. Still to be corrected is the proper use of the java properties in the java code. - karaf.home versus karaf.base - org.apache.geronimo.home.dir versus org.apache.geronimo.server.dir (and org.apache.geronimo.server.name) See GERONIMO-6270 for discussion. It is the parent task of GERONIMO-6275. > Environment variables being set in bin/geronimo does not account for named server instances > ------------------------------------------------------------------------------------------- > > Key: GERONIMO-6174 > URL: https://issues.apache.org/jira/browse/GERONIMO-6174 > Project: Geronimo > Issue Type: Bug > Security Level: public(Regular issues) > Components: startup/shutdown > Affects Versions: 3.0 > Environment: Linux x86, Red Hat Enterprise Linux Server release 5.4 (Tikanga) > Reporter: Russell E Glaue > Priority: Trivial > Labels: geronimo > > I have been able to workaround these two issues by setting properties. > Questions: > 1A) But should these properties be dynamically set relative to the named instance directory instead of GERONIMO_HOME? > 1B) Or do we require the user to explicitly set these in the environment in order to start a named instance? > 2) Does setting karaf.home in GERONIMO_OPTS as relative to the named instance directory instead of GERONIMO_HOME potentially cause any other issues? > To produce these issues follow these steps: > 1. Unpack the latest Geronimo javaee6 bundle as /opt/geronimo3 > 2. Create a Geronimo named instance directory as /opt/geronimo3/gserv1 > 3. Move the directories var, etc, and repository into /opt/geronimo3/gserv1 > 4. Use this start script > {noformat:borderStyle=solid} > #!/bin/bash > GHOME=/opt/geronimo3 > GVIRT=gserv1 > # Must change to the server directory in order to work around ActiveMQ lock > # file conflict issue reported in GERONIMO-5987. > cd ${GHOME}/${GVIRT} > # Uncomment for the Workaround of issue #1 > #export GERONIMO_TMPDIR=${GHOME}/${GVIRT}/var/temp > # > # Uncomment for the Workaround of issue #2 > #GERONIMO_OPTS="${GERONIMO_OPTS} -Dkaraf.home=${GHOME}/${GVIRT}" > # > GERONIMO_OPTS="${GERONIMO_OPTS} -Dorg.apache.geronimo.server.name=${GVIRT}" > export GERONIMO_OPTS > ${GHOME}/bin/geronimo run > {noformat} > 1) GERONIMO_TMPDIR > On startup, the `bin/geronimo` startup script sets GERONIMO_TMPDIR explicitly as > $GERONIMO_HOME/var/temp , but the actual temp directory is really > {org.apache.geronimo.server.dir}/var/temp (or > $GERONIMO_HOME/{org.apache.geronimo.server.name}/var/temp) > It does not account for the cases where an instance is being started. > {noformat:borderStyle=solid} > [user@system gserv1]# ./start.sh > Using GERONIMO_HOME: /opt/geronimo3 > Using GERONIMO_TMPDIR: /opt/geronimo3/var/temp > Using JRE_HOME: /usr/jdk1.6.0/jre > Error launching framework: java.lang.IllegalArgumentException: Invalid temporary directory. The '/opt/geronimo3/var/temp' path does not exist. > {noformat} > The workaround is to specifically specify GERONIMO_TMPDIR in your environment > before starting the instance. > 2) karaf.home > On startup, the `bin/geronimo` script sets karaf.home explicitly as > $GERONIMO_HOME . Karaf expects to use {karaf.home}/etc/shell.init.script each > time a shell session is started (See: > geronimo/server/trunk/framework/configs/karaf-framework/src/main/distribution/text/etc/system.properties). > The setting of the karaf.home property in `bin/geronimo` does not account for > the cases where a Geronimo named instance is being started. > {noformat:borderStyle=solid} > [root@rglaue7 gserv1]# ./start.sh > Using GERONIMO_HOME: /opt/geronimo3 > Using GERONIMO_TMPDIR: /opt/geronimo3/gserv1/var/temp > Using JRE_HOME: /usr/jdk1.6.0/jre > > ______ _ > / ____/___ _________ ____ (_)____ ___ ____ > / / __ / _ \/ ___/ __ \/ __ \/ // __ `__ \/ __ \ > / /_/ // __/ / / /_/ / / / / // / / / / / /_/ / > \____/ \___/_/ \____/_/ /_/_//_/ /_/ /_/\____/ > Apache Geronimo (3.0-SNAPSHOT) > Hit '' for a list of available commands > and '[cmd] --help' for help on a specific command. > Hit '' or 'osgi:shutdown' to shutdown Geronimo. > Error in initialization script: /opt/geronimo3/etc/shell.init.script (No such file or directory) > ... snip ... > {noformat} > The workaround is to set karaf.home in GERONIMO_OPTS before starting the instance. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira