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

Disk space leak with multiple copies of winstone-XXXX.jar in TEMP folder

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: core
    • Labels:
    • Environment:
      Windows 8.1 x64, JDK 1.7.0_51, Jenkins 1.553
    • Similar Issues:

      Description

      Continued operation of Jenkins creates multiple copies of "winstone.jar" with a numeric suffix in TEMP folder (winstone12343543634634.jar). We had about 800Gb of these accumulated, slowing down the host system.

      We are currently running Jenkins directly (`java -jar jenkins.jar`) via Windows scheduled task.

        Attachments

          Activity

          Hide
          ptha Peter Hannon added a comment -

          Ivan Fernandez Calvo thanks for the reply, if you see my comment (the shell script), I'm running this in linux, so the windows service change is not applicable for me.

          Are you saying for a linux environment, this generated winstone jar file needs to be cleaned manually?

          Show
          ptha Peter Hannon added a comment - Ivan Fernandez Calvo thanks for the reply, if you see my comment (the shell script), I'm running this in linux, so the windows service change is not applicable for me. Are you saying for a linux environment, this generated winstone jar file needs to be cleaned manually?
          Hide
          ifernandezcalvo Ivan Fernandez Calvo added a comment -

          Peter Hannon sorry, I've replied something unrelated.

          You have to pass an argument to enable the cleanup `--extractedFilesFolder=FOLDER_PATH`

          https://github.com/kuisathaverat/extras-executable-war/blob/8f00f05c22cb4953ed0a034e0d7ef35c0076f99f/src/main/java/Main.java#L229-L232

          Show
          ifernandezcalvo Ivan Fernandez Calvo added a comment - Peter Hannon sorry, I've replied something unrelated. You have to pass an argument to enable the cleanup `--extractedFilesFolder=FOLDER_PATH` https://github.com/kuisathaverat/extras-executable-war/blob/8f00f05c22cb4953ed0a034e0d7ef35c0076f99f/src/main/java/Main.java#L229-L232
          Hide
          ptha Peter Hannon added a comment -

          Ivan Fernandez Calvo thanks again!

          As per your suggestion, I updated my start shell script to:

           

          #!/bin/bash
          nohup /home/jenkins/jdk8/bin/java -jar /home/jenkins/jenkins.war --httpPort=8081 --extractedFilesFolder=/tmp > /home/jenkins/jenkins.log 2>&1 &
          

          Now the extra winstone jars are cleaned up on startup, I also tested a safeRestart and again there was only 1 winstone jar file (for the running Jenkins).

          So it's solved for me, cheers!

           

          Show
          ptha Peter Hannon added a comment - Ivan Fernandez Calvo  thanks again! As per your suggestion, I updated my start shell script to:   #!/bin/bash nohup /home/jenkins/jdk8/bin/java -jar /home/jenkins/jenkins.war --httpPort=8081 --extractedFilesFolder=/tmp > /home/jenkins/jenkins.log 2>&1 & Now the extra winstone jars are cleaned up on startup, I also tested a safeRestart and again there was only 1 winstone jar file (for the running Jenkins). So it's solved for me, cheers!  
          Hide
          shashankkulsh Shashank Kulshrestha added a comment -

          This issue is happening with my current Jenkins build 2.156 on windows. Is there any solution for windows for this. 

          Disk is getting full, due to so many winstone*.jar in C:\...\AppData\Local\Temp folder

          Show
          shashankkulsh Shashank Kulshrestha added a comment - This issue is happening with my current Jenkins build 2.156 on windows. Is there any solution for windows for this.  Disk is getting full, due to so many winstone*.jar in C:\...\AppData\Local\Temp folder
          Hide
          ifernandezcalvo Ivan Fernandez Calvo added a comment -

          Shashank Kulshrestha Did you read the comment before yours? there you have the solution *--extractedFilesFolder=c:\TMP-FOLDER-PATH*

          Show
          ifernandezcalvo Ivan Fernandez Calvo added a comment - Shashank Kulshrestha Did you read the comment before yours? there you have the solution * --extractedFilesFolder=c:\TMP-FOLDER-PATH *

            People

            • Assignee:
              ifernandezcalvo Ivan Fernandez Calvo
              Reporter:
              t0yv0 Anton Tayanovskyy
            • Votes:
              20 Vote for this issue
              Watchers:
              32 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: