Your Jenkins workspace is almost full












0















Jenkins has 12 different workspaces which take around 25gb.I think the problem is because in every workspace there is a copy from GIT repository which is 3gb.



Does anybody know why Jenkins is using different workspaces and why on every workspace Jenkins has a copy from the git repo ?



Probably not of the workspaces are in used. Is there a way to check which of them can be deleted ?










share|improve this question



























    0















    Jenkins has 12 different workspaces which take around 25gb.I think the problem is because in every workspace there is a copy from GIT repository which is 3gb.



    Does anybody know why Jenkins is using different workspaces and why on every workspace Jenkins has a copy from the git repo ?



    Probably not of the workspaces are in used. Is there a way to check which of them can be deleted ?










    share|improve this question

























      0












      0








      0








      Jenkins has 12 different workspaces which take around 25gb.I think the problem is because in every workspace there is a copy from GIT repository which is 3gb.



      Does anybody know why Jenkins is using different workspaces and why on every workspace Jenkins has a copy from the git repo ?



      Probably not of the workspaces are in used. Is there a way to check which of them can be deleted ?










      share|improve this question














      Jenkins has 12 different workspaces which take around 25gb.I think the problem is because in every workspace there is a copy from GIT repository which is 3gb.



      Does anybody know why Jenkins is using different workspaces and why on every workspace Jenkins has a copy from the git repo ?



      Probably not of the workspaces are in used. Is there a way to check which of them can be deleted ?







      git jenkins






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 22 '18 at 13:36









      Svetoslav AngelovSvetoslav Angelov

      163127




      163127
























          2 Answers
          2






          active

          oldest

          votes


















          1














          Two questions, two answers:




          1. For every build run in parallel, Jenkins will create a new workspace by default. 12 parallel builds = 12 workspaces. You can set it to share a workspace between multiple builds if you want, though how to do that is outside the scope of this answer because it's heavily dependent on your setup.

          2. As long as there's not a build currently running, you can delete the workspace directory freely. Or you can just modify your build to have Jenkins do that for you. Jenkins will always create a new directory if it needs to.






          share|improve this answer
























          • Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

            – Svetoslav Angelov
            Nov 22 '18 at 13:44











          • Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

            – Sebastian Lenartowicz
            Nov 22 '18 at 13:45





















          0














          Jenkins is not creating a new folder for each build by default unless running in parallel, but if you have 12 different jobs, it creates at least one folder for each job.



          Anyway, you can delete a workspace at the start and delete it also by the end of the build (better do it only if build went ok since if it fails you may want to see the content of the folder for debugging needs).



          Also, for each job, you can set the number of builds to keep or the number of days to keep, so this can reduce the number of builds.






          share|improve this answer
























          • Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

            – Svetoslav Angelov
            Nov 23 '18 at 10:13











          • I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

            – yorammi
            Nov 23 '18 at 16:10











          Your Answer






          StackExchange.ifUsing("editor", function () {
          StackExchange.using("externalEditor", function () {
          StackExchange.using("snippets", function () {
          StackExchange.snippets.init();
          });
          });
          }, "code-snippets");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "1"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53432210%2fyour-jenkins-workspace-is-almost-full%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          2 Answers
          2






          active

          oldest

          votes








          2 Answers
          2






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1














          Two questions, two answers:




          1. For every build run in parallel, Jenkins will create a new workspace by default. 12 parallel builds = 12 workspaces. You can set it to share a workspace between multiple builds if you want, though how to do that is outside the scope of this answer because it's heavily dependent on your setup.

          2. As long as there's not a build currently running, you can delete the workspace directory freely. Or you can just modify your build to have Jenkins do that for you. Jenkins will always create a new directory if it needs to.






          share|improve this answer
























          • Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

            – Svetoslav Angelov
            Nov 22 '18 at 13:44











          • Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

            – Sebastian Lenartowicz
            Nov 22 '18 at 13:45


















          1














          Two questions, two answers:




          1. For every build run in parallel, Jenkins will create a new workspace by default. 12 parallel builds = 12 workspaces. You can set it to share a workspace between multiple builds if you want, though how to do that is outside the scope of this answer because it's heavily dependent on your setup.

          2. As long as there's not a build currently running, you can delete the workspace directory freely. Or you can just modify your build to have Jenkins do that for you. Jenkins will always create a new directory if it needs to.






          share|improve this answer
























          • Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

            – Svetoslav Angelov
            Nov 22 '18 at 13:44











          • Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

            – Sebastian Lenartowicz
            Nov 22 '18 at 13:45
















          1












          1








          1







          Two questions, two answers:




          1. For every build run in parallel, Jenkins will create a new workspace by default. 12 parallel builds = 12 workspaces. You can set it to share a workspace between multiple builds if you want, though how to do that is outside the scope of this answer because it's heavily dependent on your setup.

          2. As long as there's not a build currently running, you can delete the workspace directory freely. Or you can just modify your build to have Jenkins do that for you. Jenkins will always create a new directory if it needs to.






          share|improve this answer













          Two questions, two answers:




          1. For every build run in parallel, Jenkins will create a new workspace by default. 12 parallel builds = 12 workspaces. You can set it to share a workspace between multiple builds if you want, though how to do that is outside the scope of this answer because it's heavily dependent on your setup.

          2. As long as there's not a build currently running, you can delete the workspace directory freely. Or you can just modify your build to have Jenkins do that for you. Jenkins will always create a new directory if it needs to.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Nov 22 '18 at 13:40









          Sebastian LenartowiczSebastian Lenartowicz

          3,78041834




          3,78041834













          • Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

            – Svetoslav Angelov
            Nov 22 '18 at 13:44











          • Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

            – Sebastian Lenartowicz
            Nov 22 '18 at 13:45





















          • Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

            – Svetoslav Angelov
            Nov 22 '18 at 13:44











          • Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

            – Sebastian Lenartowicz
            Nov 22 '18 at 13:45



















          Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

          – Svetoslav Angelov
          Nov 22 '18 at 13:44





          Thank you Sebastian , Is this means that Jenkins is making with every build a new workspace ? For example if i delete all workspaces , in the next build Jenkins will create a new workspace without any problems ? I`m wondering if i delete all workspace , is there a change to corrupt Jenkins at all ?

          – Svetoslav Angelov
          Nov 22 '18 at 13:44













          Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

          – Sebastian Lenartowicz
          Nov 22 '18 at 13:45







          Nope, you can delete workspaces 100% freely if they're not being used. What Jenkins will do is, if no workspaces exist, it'll create a new one. After that, if it sees that the workspace is currently in use (running a build in it), it'll create a new one.

          – Sebastian Lenartowicz
          Nov 22 '18 at 13:45















          0














          Jenkins is not creating a new folder for each build by default unless running in parallel, but if you have 12 different jobs, it creates at least one folder for each job.



          Anyway, you can delete a workspace at the start and delete it also by the end of the build (better do it only if build went ok since if it fails you may want to see the content of the folder for debugging needs).



          Also, for each job, you can set the number of builds to keep or the number of days to keep, so this can reduce the number of builds.






          share|improve this answer
























          • Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

            – Svetoslav Angelov
            Nov 23 '18 at 10:13











          • I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

            – yorammi
            Nov 23 '18 at 16:10
















          0














          Jenkins is not creating a new folder for each build by default unless running in parallel, but if you have 12 different jobs, it creates at least one folder for each job.



          Anyway, you can delete a workspace at the start and delete it also by the end of the build (better do it only if build went ok since if it fails you may want to see the content of the folder for debugging needs).



          Also, for each job, you can set the number of builds to keep or the number of days to keep, so this can reduce the number of builds.






          share|improve this answer
























          • Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

            – Svetoslav Angelov
            Nov 23 '18 at 10:13











          • I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

            – yorammi
            Nov 23 '18 at 16:10














          0












          0








          0







          Jenkins is not creating a new folder for each build by default unless running in parallel, but if you have 12 different jobs, it creates at least one folder for each job.



          Anyway, you can delete a workspace at the start and delete it also by the end of the build (better do it only if build went ok since if it fails you may want to see the content of the folder for debugging needs).



          Also, for each job, you can set the number of builds to keep or the number of days to keep, so this can reduce the number of builds.






          share|improve this answer













          Jenkins is not creating a new folder for each build by default unless running in parallel, but if you have 12 different jobs, it creates at least one folder for each job.



          Anyway, you can delete a workspace at the start and delete it also by the end of the build (better do it only if build went ok since if it fails you may want to see the content of the folder for debugging needs).



          Also, for each job, you can set the number of builds to keep or the number of days to keep, so this can reduce the number of builds.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Nov 22 '18 at 19:06









          yorammiyorammi

          3,1411624




          3,1411624













          • Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

            – Svetoslav Angelov
            Nov 23 '18 at 10:13











          • I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

            – yorammi
            Nov 23 '18 at 16:10



















          • Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

            – Svetoslav Angelov
            Nov 23 '18 at 10:13











          • I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

            – yorammi
            Nov 23 '18 at 16:10

















          Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

          – Svetoslav Angelov
          Nov 23 '18 at 10:13





          Unfortunetely we have too many builds ,and some of the builds we are using 1-2 per year and some of the other builds we are using every week . I`m not sure that there is a generic solution, because every build has own story :)

          – Svetoslav Angelov
          Nov 23 '18 at 10:13













          I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

          – yorammi
          Nov 23 '18 at 16:10





          I guess that what you refer to as 'build' is actoually a 'job' and for each 'job' you can set a different setting of how many builds to keep and/or how many days to keep

          – yorammi
          Nov 23 '18 at 16:10


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53432210%2fyour-jenkins-workspace-is-almost-full%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          404 Error Contact Form 7 ajax form submitting

          How to know if a Active Directory user can login interactively

          Refactoring coordinates for Minecraft Pi buildings written in Python