Unsupported JDK`s can cause builds to stay put in an incomplete state due to problem with log parsing

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Symptoms

When running a build, it hangs with the message that the build is incomplete and the build logs can not be viewed eventhough an incomplete version exist in the file system. Suggesting that parsing the build logs is not completed

The atlassian-bamboo.log shows the following:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 java.lang.IllegalStateException: sun.io.MalformedInputException at org.apache.commons.io.LineIterator.hasNext(LineIterator.java:107) at com.atlassian.bamboo.build.logger.BuildLogFileAccessor.getLastNLogs(BuildLogFileAccessor.java:266) at com.atlassian.bamboo.build.ViewBuildLogs.retrieveBuildLogs(ViewBuildLogs.java:44) at com.atlassian.bamboo.build.ViewBuildLogs.doExecute(ViewBuildLogs.java:33) at com.atlassian.bamboo.ww2.BambooActionSupport.execute(BambooActionSupport.java:946) at sun.reflect.GeneratedMethodAccessor433.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:618) at com.opensymphony.xwork.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:358) at com.opensymphony.xwork.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:218) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:192) at com.opensymphony.xwork.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:175) at com.atlassian.bamboo.ww2.interceptors.BambooWorkflowInterceptor.doIntercept(BambooWorkflowInterceptor.java:33) at com.opensymphony.xwork.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:190) at com.opensymphony.xwork.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:116) at com.atlassian.bamboo.ww2.interceptors.BambooValidationInterceptor.doIntercept(BambooValidationInterceptor.java:33) at com.opensymphony.xwork.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:190) at com.atlassian.bamboo.ww2.interceptors.JSONValidationInterceptor.intercept(JSONValidationInterceptor.java:78) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:190) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:31) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:190)

Cause

You are most likely using an unsupported JDK against your Bamboo server or remote agent. So far, this issue is common with IBM JDK 1.5 on SUSE Linux OS. The root of the problem is the $LANG environment variable where if the $LANG contains a locale with the ".UTF-8" suffix, Java expects all input files to be encoded using UTF-8.

Resolution

A workaround that might help will be to change the encoding to something else which might also break other stuffs in future like weird characters not correctly displayed will be to change the encoding scheme. To do that, try the following:

  1. Shutdown Bamboo

  2. Navigate to the conf/wrapper.conf file and open it for edit

  3. Add this line:

    1 wrapper.java.additional.5=-Dfile.encoding=ISO-8859-1

Please replace the number 5 with the next available digit in the series of java addditonals

4. Restart BAMBOO and check that your system encoding changes to ISO-8859-1 from the general configuration page.

If possible try to change the JDK to a supported one

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.