wrapper version; 3.5.53
Java process startup (with -javaagent) fails, due to default 2 sec startup criteria. As pr documentation https://wrapper.tanukisoftware.com/doc/english/integrate-start-stop-nix.html#TuneUp tried bypassing the default timeout settings. But unable to do so, as if they dont seem to impact.
wrapper.java.additional.1=-Dorg.tanukisoftware.wrapper.WrapperStartStopApp.waitForStartMain=TRUE
&
wrapper.java.additional.1=-Dorg.tanukisoftware.wrapper.WrapperStartStopApp.maxStartMainWait=300
However, with in debug mode the process (with -javaagent) starts properly since debug overrides the WrapperStartStopApp.maxStartMainWait system property as documented.
How shall the wrapper configuration be debugged further? Following is the process log in wrapper verbose mode:
[startup.sh] Starting a plain Tanuki process...
Running Software AG Integration Server 11.1 (default)...
wrapper | Configured log file set to '/Applications/IS111/IntegrationServer/instances/default/logs/wrapper.log'.
wrapper | Base configuration file is /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper.conf
wrapper | Found #include file in /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper.conf: %INSTALL_AREA%/configuration/wrapper-license.conf
wrapper | After environment variable replacements: /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper-license.conf
wrapper | Reading included configuration file, /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper-license.conf
wrapper | The "wrapper.anchorfile" property was defined on the Wrapper command line and can not be overwritten.
wrapper | Ignoring redefinition on line #108 of configuration file: /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper.conf
wrapper | Fixed Value wrapper.anchorfile=/Applications/IS111/IntegrationServer/instances/default/bin/wrapper.anchor
wrapper | Ignored Value wrapper.anchorfile=/Applications/IS111/IntegrationServer/instances/default/bin/wrapper.anchor
wrapper | Found #include file in /Applications/IS111/IntegrationServer/instances/default/configuration/wrapper.conf: %INSTALL_AREA%/configuration/custom_wrapper.conf
wrapper | After environment variable replacements: /Applications/IS111/IntegrationServer/instances/default/configuration/custom_wrapper.conf
wrapper | Reading included configuration file, /Applications/IS111/IntegrationServer/instances/default/configuration/custom_wrapper.conf
wrapper | --> Wrapper Started as Console
wrapper | Java Service Wrapper Standard Edition 64-bit 3.5.53
wrapper | Copyright (C) 1999-2023 Tanuki Software, Ltd. All Rights Reserved.
wrapper | http://wrapper.tanukisoftware.com
wrapper | Licensed to Software AG for Software AG Integration Server
wrapper |
wrapper | Release time: 2023/03/09 00:00:00
wrapper | Build time: 2023/03/08 19:07:00
wrapper | Timezone: IST (+0630) Offset: -19800, hasDaylight: 1
wrapper | Using tick timer.
wrapper | PID: 79129
wrapper | Signal trapped. Details:
wrapper | signal number=20 (SIGCHLD), source="unknown"
wrapper | Received a 'SIGCHLD' signal. Checking JVM process status.
wrapper | Java version: 17.0.13
wrapper | Java vendor: OpenJDK
wrapper | Java bits: 64-Bit
wrapper | Reading the JVM output using the encoding of the current locale (UTF-8).
wrapper | Classpath element, wrapper.java.classpath.2, does not exist: %JAVA_SYSTEM_CLASSPATH%
wrapper | Classpath element, wrapper.java.classpath.3, does not exist: /Applications/IS111/common/lib/wm-converters.jar
wrapper | Resolved the real path of wrapper.java.command as an absolute reference: /Applications/IS111/jvm/jvm/bin/java
wrapper | Magic number for file /Applications/IS111/jvm/jvm/bin/java: 0xcffaedfe
wrapper | The 'JAVA_BOOT_CLASSPATH' environment variable was referenced but has not been defined.
wrapper | Startup Timeouts: wrapper.startup.timeout=30, wrapper.startup.delay.console=0, wrapper.startup.delay.service=0, wrapper.restart.delay=5
wrapper | Ping settings: wrapper.ping.interval=5, wrapper.ping.interval.logged=1, wrapper.ping.timeout=300, wrapper.ping.alert.threshold=75
wrapper | Shutdown Timeouts: wrapper.shutdown.timeout=0, wrapper.jvm_exit.timeout=0, wrapper.jvm_cleanup.timeout=10, wrapper.jvm_terminate.timeout=10
wrapper | Launching a JVM...
wrapper | JVM started (PID=79131)
wrapper | Signal trapped. Details:
wrapper | signal number=20 (SIGCHLD), source="unknown"
wrapper | Received a 'SIGCHLD' signal. Checking JVM process status.
wrapper | JVM process exited with a code of 1, setting the Wrapper exit code to 1.
wrapper | JVM exited while loading the application.
wrapper | The thread reading stdin is not responding. Stop reading console input.
wrapper | Preparing to restart with mode 2.
wrapper | Automatic JVM Restarts disabled. Shutting down.
wrapperp | closing backend server.
wrapper | Exit code: 1
wrapper | <-- Wrapper Stopped
Hello Sanjib,
Thank you for reporting this issue.
The startup waiting time, which defaults to 2 seconds, is not criterion of success or failure. It just defines the number of seconds that the WrapperStartStopApp class will wait before assuming that the application has started. In other words, both cases where the main method completes before or after the 2 seconds will be considered successful (as long as the exit code is 0).
Looking at the log output you sent, the Wrapper process is receiving a SIGCHLD from the JVM and detects that the JVM has terminated. This can happen if your main class called system.exit(1) or returned with error code 1.
The log you attached is a bit difficult to read because there is not timestamps and no column to distinguish the source (JVM vs Wrapper). You may want to add the 'P' and 'T' column to show this information:
https://wrapper.tanukisoftware.com/doc/english/prop-console-format.html
Did you remove some lines from the output? In debug mode, the Wrapper should show more output like the command line, etc.. These messages are also helpful in understanding issues.
Do you encounter the same issue when running without -javaagent? It would be interesting to see the command lines generated by the Wrapper when this option is added.
If possible, please send us your full log file on a private email at support@tanukisoftware.com.
Best Regards,
Maxime