glassfish
  1. glassfish
  2. GLASSFISH-19653

JVM Invocation Command No Longer Gets Logged

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 4.0_b70
    • Fix Version/s: 4.0_b73
    • Component/s: logging
    • Labels:
      None

      Description

      The GlassFish launcher goes to quite a bit of trouble logging the entire gigantic JVM invocation line. It has always appeared in the server log as the first item.

      It no longer appears in the server log at all.

      The only way you can see it is to start DAS or instances in verbose mode. E.g.

      asadmin start-domain -v

      If you want to explore how the JVM invocation line is created and logged see the module "admin/launcher"

        Activity

        Hide
        Byron Nevins added a comment -

        Typical output seen with the verbose option:

        eb 07, 2013 3:13:18 PM com.sun.enterprise.admin.launcher.GFLauncherLogger info
        INFO: JVM invocation command line:
        /Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/bin/java
        -cp
        /Users/wnevins/glassfish3/glassfish/modules/glassfish.jar
        -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=9009
        -XX:+UnlockDiagnosticVMOptions
        -XX:MaxPermSize=192m
        -XX:NewRatio=2
        -Xmx512m
        -client
        -javaagent:/Users/wnevins/glassfish3/glassfish/lib/monitor/flashlight-agent.jar
        -Dfelix.fileinstall.disableConfigSave=false
        -Djavax.net.ssl.keyStore=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/keystore.jks
        -Djava.awt.headless=true
        -Dfelix.fileinstall.poll=5000
        -Djava.endorsed.dirs=/Users/wnevins/glassfish3/glassfish/modules/endorsed:/Users/wnevins/glassfish3/glassfish/lib/endorsed
        -Dfelix.fileinstall.bundles.startTransient=true
        -Djavax.net.ssl.trustStore=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/cacerts.jks
        -Dcom.sun.enterprise.security.httpsOutboundKeyAlias=s1as
        -DANTLR_USE_DIRECT_CLASS_LOADING=true
        -Djava.security.auth.login.config=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/login.conf
        Dgosh.args=-nointeractive
        -Dosgi.shell.telnet.maxconn=1
        -Djdbc.drivers=org.apache.derby.jdbc.ClientDriver
        -Dfelix.fileinstall.dir=/Users/wnevins/glassfish3/glassfish/modules/autostart/
        -Dosgi.shell.telnet.port=6666
        -Djava.security.policy=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/server.policy
        -Dfelix.fileinstall.log.level=2
        -Dcom.sun.aas.instanceRoot=/Users/wnevins/glassfish3/glassfish/domains/domain1
        -Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
        -Dosgi.shell.telnet.ip=127.0.0.1
        -Dcom.sun.aas.installRoot=/Users/wnevins/glassfish3/glassfish
        -Djava.ext.dirs=/Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/lib/ext:/Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/jre/lib/ext:/Users/wnevins/glassfish3/glassfish/domains/domain1/lib/ext
        -Dfelix.fileinstall.bundles.new.start=true
        -Dorg.glassfish.additionalOSGiBundlesToStart=org.apache.felix.shell,org.apache.felix.gogo.runtime,org.apache.felix.gogo.shell,org.apache.felix.gogo.command,org.apache.felix.shell.remote,org.apache.felix.fileinstall
        -DwriteDefaultElementsToXml=true
        -Djava.library.path=/Users/wnevins/glassfish3/glassfish/lib:/Users/wnevins/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:/Users/wnevins
        com.sun.enterprise.glassfish.bootstrap.ASMain
        -domainname
        domain1
        -asadmin-args
        -host,,,localhost,,,port,,,4848,,,secure=false,,,terse=false,,,echo=false,,,interactive=true,,,start-domain,,,verbose=true,,,watchdog=false,,,debug=true,,,-domaindir,,,/Users/wnevins/glassfish3/glassfish/domains,,,domain1
        -instancename
        server
        -verbose
        true
        -debug
        true
        -asadmin-classpath
        /Users/wnevins/glassfish3/glassfish/lib/client/appserver-cli.jar
        -asadmin-classname
        com.sun.enterprise.admin.cli.AdminMain
        -upgrade
        false
        -type
        DAS
        -domaindir
        /Users/wnevins/glassfish3/glassfish/domains/domain1
        -read-stdin
        true

        Show
        Byron Nevins added a comment - Typical output seen with the verbose option: eb 07, 2013 3:13:18 PM com.sun.enterprise.admin.launcher.GFLauncherLogger info INFO: JVM invocation command line: /Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/bin/java -cp /Users/wnevins/glassfish3/glassfish/modules/glassfish.jar -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=9009 -XX:+UnlockDiagnosticVMOptions -XX:MaxPermSize=192m -XX:NewRatio=2 -Xmx512m -client -javaagent:/Users/wnevins/glassfish3/glassfish/lib/monitor/flashlight-agent.jar -Dfelix.fileinstall.disableConfigSave=false -Djavax.net.ssl.keyStore=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/keystore.jks -Djava.awt.headless=true -Dfelix.fileinstall.poll=5000 -Djava.endorsed.dirs=/Users/wnevins/glassfish3/glassfish/modules/endorsed:/Users/wnevins/glassfish3/glassfish/lib/endorsed -Dfelix.fileinstall.bundles.startTransient=true -Djavax.net.ssl.trustStore=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/cacerts.jks -Dcom.sun.enterprise.security.httpsOutboundKeyAlias=s1as -DANTLR_USE_DIRECT_CLASS_LOADING=true -Djava.security.auth.login.config=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/login.conf Dgosh.args= -nointeractive -Dosgi.shell.telnet.maxconn=1 -Djdbc.drivers=org.apache.derby.jdbc.ClientDriver -Dfelix.fileinstall.dir=/Users/wnevins/glassfish3/glassfish/modules/autostart/ -Dosgi.shell.telnet.port=6666 -Djava.security.policy=/Users/wnevins/glassfish3/glassfish/domains/domain1/config/server.policy -Dfelix.fileinstall.log.level=2 -Dcom.sun.aas.instanceRoot=/Users/wnevins/glassfish3/glassfish/domains/domain1 -Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory -Dosgi.shell.telnet.ip=127.0.0.1 -Dcom.sun.aas.installRoot=/Users/wnevins/glassfish3/glassfish -Djava.ext.dirs=/Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/lib/ext:/Library/Java/JavaVirtualMachines/jdk1.7.0_10.jdk/Contents/Home/jre/lib/ext:/Users/wnevins/glassfish3/glassfish/domains/domain1/lib/ext -Dfelix.fileinstall.bundles.new.start=true -Dorg.glassfish.additionalOSGiBundlesToStart=org.apache.felix.shell,org.apache.felix.gogo.runtime,org.apache.felix.gogo.shell,org.apache.felix.gogo.command,org.apache.felix.shell.remote,org.apache.felix.fileinstall -DwriteDefaultElementsToXml=true -Djava.library.path=/Users/wnevins/glassfish3/glassfish/lib:/Users/wnevins/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:/Users/wnevins com.sun.enterprise.glassfish.bootstrap.ASMain -domainname domain1 -asadmin-args - host,,,localhost,,, port,,,4848,,, secure=false,,, terse=false,,, echo=false,,, interactive=true,,,start-domain,,, verbose=true,,, watchdog=false,,, debug=true,,, -domaindir,,,/Users/wnevins/glassfish3/glassfish/domains,,,domain1 -instancename server -verbose true -debug true -asadmin-classpath /Users/wnevins/glassfish3/glassfish/lib/client/appserver-cli.jar -asadmin-classname com.sun.enterprise.admin.cli.AdminMain -upgrade false -type DAS -domaindir /Users/wnevins/glassfish3/glassfish/domains/domain1 -read-stdin true
        Hide
        Byron Nevins added a comment -

        Marina Vatkina pointed out that it DOES get logged – but it appears in a file. Apparently the log is immediately rotated. Why?

        rw-rr- 1 wnevins staff 11274 Feb 7 15:13 server.log
        rw-rr- 1 wnevins staff 3227 Feb 7 15:10 server.log_2013-02-07T15-10-32

        Show
        Byron Nevins added a comment - Marina Vatkina pointed out that it DOES get logged – but it appears in a file. Apparently the log is immediately rotated. Why? rw-r r - 1 wnevins staff 11274 Feb 7 15:13 server.log rw-r r - 1 wnevins staff 3227 Feb 7 15:10 server.log_2013-02-07T15-10-32
        Hide
        rajendra_inamdar added a comment -

        Can you check if there is a rotated file in the logs directory which has the above message that you are looking for.

        Show
        rajendra_inamdar added a comment - Can you check if there is a rotated file in the logs directory which has the above message that you are looking for.
        Hide
        rajendra_inamdar added a comment -

        The launcher logs the JVM command line which is a multi-line message. Subsequently, when the instance process starts, it attempts to check the log format by parsing first few lines. The intent is to rotate the log if a format change is detected. Multi-line messages are incorrectly handled in this case causing it to infer a format change, which results in log rotation.

        Show
        rajendra_inamdar added a comment - The launcher logs the JVM command line which is a multi-line message. Subsequently, when the instance process starts, it attempts to check the log format by parsing first few lines. The intent is to rotate the log if a format change is detected. Multi-line messages are incorrectly handled in this case causing it to infer a format change, which results in log rotation.
        Hide
        sandeep.shrivastava added a comment -

        Committed revision 59329.

        Show
        sandeep.shrivastava added a comment - Committed revision 59329.

          People

          • Assignee:
            sandeep.shrivastava
            Reporter:
            Byron Nevins
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: