Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-22345

disk-usage-plugin causes jobs to hang at the end for 5min

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      We noticed the following strange behaviour on quite a lot of our jobs.

      After all build steps and post build steps finished, the build is in some quite inconsistent state for up to exactly 5min:

      • the Console is still spinning with no output
      • the big ball of the job is still blinking
      • starting the job again results in "current job is already building"
        ALTHOUGH
      • the build is shown as finished in the build history of the job
      • it has disappeared from the slave it was running on

      I especially liked the build history, when you start a new build #128, it says, build #127 is still in progress, and right below you see a quite finished build #127

      We double checked enabling and disabling the disk-usage-plugin, and it was clearly causing this issue. The 5min are probably some kind of timeout somewhere.

        Attachments

          Issue Links

            Activity

            Hide
            nancyrobertson Nancy Robertson added a comment - - edited

            I have encountered this issue on my Jenkins installation with a subset of the jobs.
            The jobs that have this problem are the ones that have a Custom Workspace defined.

            After the job finishes, the jenkins process on the master starts using a lot of CPU while the Disk Usage plugin is trying to estimate the size of the workspace on the slave.
            While this is happening, the build history for the job shows that it has finished, but the job is still shown in the Build Executor Status and the console log for the build does not show the expected last statement of "Finished: SUCCESS".
            This goes on for 5 minutes, which happens to match the configured value of the timeout for calculating the size of the workspace on slaves.

            Not sure if this matters, but our jobs are of type: "free-style software project" and the version of Jenkins we use is 1.566
            We had version 0.23 of the disk usage plugin, the problem went away by uninstalling the plugin.

            Show
            nancyrobertson Nancy Robertson added a comment - - edited I have encountered this issue on my Jenkins installation with a subset of the jobs. The jobs that have this problem are the ones that have a Custom Workspace defined. After the job finishes, the jenkins process on the master starts using a lot of CPU while the Disk Usage plugin is trying to estimate the size of the workspace on the slave. While this is happening, the build history for the job shows that it has finished, but the job is still shown in the Build Executor Status and the console log for the build does not show the expected last statement of "Finished: SUCCESS". This goes on for 5 minutes, which happens to match the configured value of the timeout for calculating the size of the workspace on slaves. Not sure if this matters, but our jobs are of type: "free-style software project" and the version of Jenkins we use is 1.566 We had version 0.23 of the disk usage plugin, the problem went away by uninstalling the plugin.
            Hide
            lvotypkova Lucie Votypkova added a comment -

            Hi,
            I think I know what is the problem. If you use share workspace and it is big (there is a lot of other stuff then only particular job workspace), it could try to calculate size for all files and subfiles - it can take a lot of time. Disk usage is called by listener after all build steps are finished and result is set (failed disk usage does not mean that build should change its result). But it is strange that build history shows that build is finished, because it should not be in state completed. I will try to reproduce this issue, but with disk-usage 0.26 and Jenkins 1.580 which are current used versions.

            You can check if disk-usage perform calculation in build log, there should be info message that calculation is in progress.

            Show
            lvotypkova Lucie Votypkova added a comment - Hi, I think I know what is the problem. If you use share workspace and it is big (there is a lot of other stuff then only particular job workspace), it could try to calculate size for all files and subfiles - it can take a lot of time. Disk usage is called by listener after all build steps are finished and result is set (failed disk usage does not mean that build should change its result). But it is strange that build history shows that build is finished, because it should not be in state completed. I will try to reproduce this issue, but with disk-usage 0.26 and Jenkins 1.580 which are current used versions. You can check if disk-usage perform calculation in build log, there should be info message that calculation is in progress.
            Hide
            catonyx Todd B added a comment -

            I am seeing this exact problem. Is there a way too turn this off for certain jobs?

            Show
            catonyx Todd B added a comment - I am seeing this exact problem. Is there a way too turn this off for certain jobs?

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              marc_guenther Marc G√ľnther
              Votes:
              13 Vote for this issue
              Watchers:
              17 Start watching this issue

                Dates

                Created:
                Updated: