Windows service fails to start: The process terminated unexpectedly
要約
Running Bamboo as a Windows service fails with: The process terminated unexpectedly.
原因
- The user that's running the service is root and not a local user.
- Incompatible JDK version or having more than one JDKs (Example: 32-bit JDK and 64-bit JDK).
The "wrapper.conf" file is missing from <bamboo-installation-directory>/conf due to an unfinished/corrupted installation or upgrade.
JAVA_HOME is not set up or not pointing to the correct directory.
The PATH environment variable doesn't include the JDK directory or it's located after the system32 path.
ソリューション
- Make sure that the user running Bamboo is a local user and not root: Running Bamboo service on Windows as the local user.
- Check that there is only one JDK installed on the machine and that its version is compatible with the version of Bamboo: Bamboo supported platforms. (Check the java version by running java -version)
- Make sure that the
wrapper.conf
file exists in the <bamboo-installation-directory>/conf. If Bamboo can be started manually, it shows that this file exists. - Run
echo %JAVA_HOME%
and check if it's pointing to the correct JDK. (Ex.: C:\Program Files\Java\jdk1.8.0_255) - Confirm that the %PATH% environment variable contains the current JDK in its definition and that it comes before the system32 path.
Try to explicitly set the path to the Java installation in the parameter
"wrapper.java.command"
in the wrapper.conf file. This parameter value is by default java, update it to look into the exact directory (Ex: C:/Program Files/Java/jdk1.8.0_255/bin/java.exe).