Karaf
  1. Karaf
  2. KARAF-1241

admin script does not pass on JAVA_OPTS to instance

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 2.2.5
    • Fix Version/s: 2.2.6, 3.0.0
    • Component/s: None
    • Labels:
      None
    • Environment:

      apache-karaf-2.2.5.tar.gz

      Description

      The JAVA_OPTS set in the bin/admin script are passed on to the admin process but then when the admin process kicks off a new Karaf instance, the options get lost. For example, when setting the max JVM memory to 1024M as follows:

      [janstey@duffman apache-karaf-2.2.5]$ export JAVA_MAX_MEM=1024M
      

      You can see that the default of 512M is still used for the Karaf instance:

      [janstey@duffman apache-karaf-2.2.5]$ ./bin/admin start root
      [org.apache.karaf.admin.internal.InstanceImpl] : Starting instance root with command: /opt/jdk1.6.0_23/jre/bin/java -server -Xmx512M -Dcom.sun.management.jmxremote  -Djava.util.logging.config.file="/opt/fuse/apache-karaf-2.2.5/etc/java.util.logging.properties" -Djava.endorsed.dirs="/opt/jdk1.6.0_23/jre/jre/lib/endorsed:/opt/jdk1.6.0_23/jre/lib/endorsed:/opt/fuse/apache-karaf-2.2.5/lib/endorsed" -Djava.ext.dirs="/opt/jdk1.6.0_23/jre/jre/lib/ext:/opt/jdk1.6.0_23/jre/lib/ext:/opt/fuse/apache-karaf-2.2.5/lib/ext" -Dkaraf.home="/opt/fuse/apache-karaf-2.2.5" -Dkaraf.base="/opt/fuse/apache-karaf-2.2.5" -Dkaraf.startLocalConsole=false -Dkaraf.startRemoteShell=true -classpath /opt/fuse/apache-karaf-2.2.5/lib/karaf.jar:/opt/fuse/apache-karaf-2.2.5/lib/karaf-jaas-boot.jar org.apache.karaf.main.Main
      

      Attaching a fix shortly.

      1. KARAF-1241.patch
        2 kB
        Jonathan Anstey

        Activity

        Jamie goodyear made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Jean-Baptiste Onofré made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Won't Fix [ 2 ]
        Jean-Baptiste Onofré made changes -
        Fix Version/s 2.2.6 [ 12319142 ]
        Fix Version/s 3.0.0 [ 12316040 ]
        Jean-Baptiste Onofré made changes -
        Assignee Jean-Baptiste Onofré [ jbonofre ]
        Jonathan Anstey made changes -
        Field Original Value New Value
        Attachment KARAF-1241.patch [ 12516390 ]
        Jonathan Anstey created issue -

          People

          • Assignee:
            Jean-Baptiste Onofré
            Reporter:
            Jonathan Anstey
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development