|
Is there an easy way (a plugin?) to remove old builds? We
have jobs that have hundreds of old builds that are no longer needed and which
consume quite a bit of disk space. I can delete the folders under the jobs/<jobname>/builds
folder through the file system, but that still leaves the links to the
individual builds in the left pane of the Hudson pages. I want to delete the
builds completely from |
|
Why don't you use the build-in feature "remove old builds"?
2009/7/25 David Ngan <[hidden email]>: > Is there an easy way (a plugin?) to remove old builds? We have jobs that > have hundreds of old builds that are no longer needed and which consume > quite a bit of disk space. I can delete the folders under the > jobs/<jobname>/builds folder through the file system, but that still leaves > the links to the individual builds in the left pane of the Hudson pages. I > want to delete the builds completely from Hudson, including the links, just > as if using the “Delete this build” button. It would be ideal to be able to > specify the starting and ending build numbers to delete. > > > > -- Mit freundlichen Grüßen / Regards Marc Lustig Lustig IT-Consulting Selma-Lagerlöf-Str. 92 81829 München Tel. +49 (0)163-3798237 Fax +49 (0)89-38535572 Email: [hidden email] Steuer-Nr.: 145/184/90649 USt-ID-Nr.: DE246455267 --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] |
|
"Discard old builds" is useful in many situations, either by days or number of builds. Sometimes it would be helpful to be able to discard all builds prior to build 7500, for example, where build 7500 might be a special release or maintenance build. A kind of one-time clean-up operation where the builds deleted are determined by a build number rather than by days or number of builds.
-----Original Message----- From: [hidden email] [mailto:[hidden email]] On Behalf Of Marc Lustig Sent: Saturday, July 25, 2009 3:25 PM To: [hidden email] Subject: Re: How to purge old builds Why don't you use the build-in feature "remove old builds"? 2009/7/25 David Ngan <[hidden email]>: > Is there an easy way (a plugin?) to remove old builds? We have jobs that > have hundreds of old builds that are no longer needed and which consume > quite a bit of disk space. I can delete the folders under the > jobs/<jobname>/builds folder through the file system, but that still leaves > the links to the individual builds in the left pane of the Hudson pages. I > want to delete the builds completely from Hudson, including the links, just > as if using the "Delete this build" button. It would be ideal to be able to > specify the starting and ending build numbers to delete. > > > > -- Mit freundlichen Grüßen / Regards Marc Lustig Lustig IT-Consulting Selma-Lagerlöf-Str. 92 81829 München Tel. +49 (0)163-3798237 Fax +49 (0)89-38535572 Email: [hidden email] Steuer-Nr.: 145/184/90649 USt-ID-Nr.: DE246455267 --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] |
|
In reply to this post by David Ngan
The easiest way is to change the configuration for that project to delete old builds when you create a new build. This allows you to specify how old a build has to be in order to delete, or how many builds you want to keep.
If there are specific builds you want to keep, you can go into that build once you've set the delete old build option, and then click on the "Keep this build forever" button. Then, trigger a build, and the old builds you want to delete are purged from Hudson. I've dones purging using "find $dir -mtime +$age -rm" where age is the oldest date you want to keep the build (in days). This will get rid of the builds and the links. You may have to restart Hudosn once this is done in order for the GUI to show that the builds are no longer available. On Sat, Jul 25, 2009 at 1:13 PM, David Ngan <[hidden email]> wrote:
-- David Weintraub [hidden email] |
|
Good information. This should work for
me. Thanks! From: David Weintraub
[mailto:[hidden email]] The easiest way is to
change the configuration for that project to delete old builds when you create
a new build. This allows you to specify how old a build has to be in order to
delete, or how many builds you want to keep. On Sat, Jul 25, 2009 at 1:13 PM, David Ngan <[hidden email]> wrote: Is
there an easy way (a plugin?) to remove old builds? We have jobs that have
hundreds of old builds that are no longer needed and which consume quite a bit
of disk space. I can delete the folders under the jobs/<jobname>/builds
folder through the file system, but that still leaves the links to the individual
builds in the left pane of the Hudson pages. I want to delete the builds
completely from
|
|
Administrator
|
In reply to this post by David Ngan
David Ngan wrote:
> "Discard old builds" is useful in many situations, either by days or number of builds. Sometimes it would be helpful to be able to discard all builds prior to build 7500, for example, where build 7500 might be a special release or maintenance build. A kind of one-time clean-up operation where the builds deleted are determined by a build number rather than by days or number of builds. This would be a good CLI. java -jar hudson-cli.jar delete-builds myproject -7500 Any volunteer :-) ? > > -----Original Message----- > From: [hidden email] [mailto:[hidden email]] On Behalf Of Marc Lustig > Sent: Saturday, July 25, 2009 3:25 PM > To: [hidden email] > Subject: Re: How to purge old builds > > Why don't you use the build-in feature "remove old builds"? > > 2009/7/25 David Ngan <[hidden email]>: >> Is there an easy way (a plugin?) to remove old builds? We have jobs that >> have hundreds of old builds that are no longer needed and which consume >> quite a bit of disk space. I can delete the folders under the >> jobs/<jobname>/builds folder through the file system, but that still leaves >> the links to the individual builds in the left pane of the Hudson pages. I >> want to delete the builds completely from Hudson, including the links, just >> as if using the "Delete this build" button. It would be ideal to be able to >> specify the starting and ending build numbers to delete. >> >> >> >> > > > -- Kohsuke Kawaguchi Sun Microsystems http://weblogs.java.net/blog/kohsuke/ |
|
This post has NOT been accepted by the mailing list yet.
Thanks, Kohsuke Kawaguchi. it works. Just need minor chnage
java -jar jenkins-cli.jar -s http://my.jenkins.host delete-builds myproject '1-7499' --username $user --password $password Deleted 7499 builds |
| Powered by Nabble | Edit this page |
