[
https://issues.apache.org/jira/browse/MRM-2014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17136106#comment-17136106
]
Jason Grammenos commented on MRM-2014:
--------------------------------------
archiva-02-redacted.png
in this image we can see more versions than the retention policy
and on disk we can both see the folders and the folder contents are still on
disk
am i not understanding how the retention works?
are you telling me that there is no way to set a retention count on version
(retain only the last x versions)?
because if you cannot set retention on versions, I would strongly recommend
adding that feature. Versions will eventually consume all available disk space
as new versions are released. and simply delete the folders on disk via a linux
based cron job with a rm/find command will probably have adverse affects on
archiva's database tracking of versions. This means one would need to implement
a complex cron job using api calls to remove old versions.
{noformat}
jason.grammenos@archiva:/opt/archiva/repositories/repositories/projectname/com/companyname/projectname/api-model$
ll
total 224
drwxr-xr-x 51 root root 4096 Jun 9 16:43 ./
drwxr-xr-x 7 root root 4096 Jul 18 2019 ../
drwxr-xr-x 2 root root 4096 Apr 9 2019 1.0.0/
drwxr-xr-x 2 root root 4096 Apr 26 2019 1.0.1/
drwxr-xr-x 2 root root 4096 Jul 31 2019 1.0.10/
drwxr-xr-x 2 root root 4096 Aug 9 2019 1.0.11/
drwxr-xr-x 2 root root 4096 Aug 13 2019 1.0.12/
drwxr-xr-x 2 root root 4096 Aug 16 2019 1.0.13/
drwxr-xr-x 2 root root 4096 Aug 19 2019 1.0.14/
drwxr-xr-x 2 root root 4096 Aug 19 2019 1.0.15/
drwxr-xr-x 2 root root 4096 Aug 20 2019 1.0.16/
drwxr-xr-x 2 root root 4096 Sep 6 2019 1.0.17/
drwxr-xr-x 2 root root 4096 Sep 11 2019 1.0.18-SNAPSHOT/
drwxr-xr-x 2 root root 4096 Sep 18 2019 1.0.19/
drwxr-xr-x 2 root root 4096 Apr 29 2019 1.0.2/
drwxr-xr-x 2 root root 4096 Oct 3 2019 1.0.20/
drwxr-xr-x 2 root root 4096 Oct 3 2019 1.0.20-SNAPSHOT/
drwxr-xr-x 2 root root 4096 Oct 9 2019 1.0.21/
drwxr-xr-x 2 root root 4096 Nov 29 2019 1.0.22/
drwxr-xr-x 2 root root 4096 Dec 16 12:04 1.0.23/
drwxr-xr-x 2 root root 4096 Dec 17 15:04 1.0.24/
drwxr-xr-x 2 root root 4096 Dec 18 13:04 1.0.25/
drwxr-xr-x 2 root root 4096 Jan 6 15:04 1.0.26/
drwxr-xr-x 2 root root 4096 Jan 14 14:04 1.0.27/
drwxr-xr-x 2 root root 4096 Jan 28 18:05 1.0.28/
drwxr-xr-x 2 root root 4096 Jan 30 17:04 1.0.29/
drwxr-xr-x 2 root root 4096 Jan 30 17:04 1.0.30/
drwxr-xr-x 2 root root 4096 Jan 30 17:04 1.0.31/
drwxr-xr-x 2 root root 4096 Feb 6 18:05 1.0.32/
drwxr-xr-x 2 root root 4096 Feb 18 17:04 1.0.33/
drwxr-xr-x 2 root root 4096 Feb 24 14:04 1.0.34/
drwxr-xr-x 2 root root 4096 Mar 2 15:31 1.0.34-SNAPSHOT/
drwxr-xr-x 2 root root 4096 Mar 10 18:05 1.0.35/
drwxr-xr-x 2 root root 4096 Mar 11 09:42 1.0.35-SNAPSHOT/
drwxr-xr-x 2 root root 4096 May 17 2019 1.0.4/
drwxr-xr-x 2 root root 4096 May 31 2019 1.0.5/
drwxr-xr-x 2 root root 4096 Jun 20 2019 1.0.6/
drwxr-xr-x 2 root root 4096 Jul 9 2019 1.0.7/
drwxr-xr-x 2 root root 4096 Jul 10 2019 1.0.8/
drwxr-xr-x 2 root root 4096 Jul 10 2019 1.0.8-HOTFIX/
drwxr-xr-x 2 root root 4096 Jul 24 2019 1.0.9/
drwxr-xr-x 2 root root 4096 Mar 19 17:04 2.0.0/
drwxr-xr-x 2 root root 4096 Mar 25 10:56 2.0.1-SNAPSHOT/
drwxr-xr-x 2 root root 4096 Apr 2 16:03 2.0.2/
drwxr-xr-x 2 root root 4096 Apr 15 17:03 2.0.3/
drwxr-xr-x 2 root root 4096 Apr 27 17:03 2.0.4/
drwxr-xr-x 2 root root 4096 May 14 18:03 2.0.5/
drwxr-xr-x 2 root root 4096 May 20 15:10 2.0.5-SNAPSHOT/
drwxr-xr-x 2 root root 4096 Jun 9 14:03 2.0.6/
drwxr-xr-x 2 root root 4096 Jun 9 16:43 2.0.6-SNAPSHOT/
drwxr-xr-x 2 root root 12288 Jun 15 11:40 2.0.7-SNAPSHOT/
-rw-r--r-- 1 root root 1740 Jun 15 12:03 maven-metadata.xml
-rw-r--r-- 1 root root 52 Jun 15 12:03 maven-metadata.xml.md5
-rw-r--r-- 1 root root 60 Jun 15 12:03 maven-metadata.xml.sha1
jason.grammenos@mm02archiva01:/opt/archiva/repositories/repositories/projectname/com/companyname/projectname/api-model$
cd 1.0.0/
jason.grammenos@mm02archiva01:/opt/archiva/repositories/repositories/projectname/com/companyname/projectname/api-model/1.0.0$
ll
total 512
drwxr-xr-x 2 root root 4096 Apr 9 2019 ./
drwxr-xr-x 51 root root 4096 Jun 9 16:43 ../
-rw-r--r-- 1 root root 253157 Apr 9 2019 api-model-1.0.0.jar
-rw-r--r-- 1 root root 32 Apr 9 2019 api-model-1.0.0.jar.md5
-rw-r--r-- 1 root root 40 Apr 9 2019 api-model-1.0.0.jar.sha1
-rw-r--r-- 1 root root 6205 Apr 9 2019 api-model-1.0.0.pom
-rw-r--r-- 1 root root 32 Apr 9 2019 api-model-1.0.0.pom.md5
-rw-r--r-- 1 root root 40 Apr 9 2019 api-model-1.0.0.pom.sha1
-rw-r--r-- 1 root root 149570 Apr 9 2019 api-model-1.0.0-sources.jar
-rw-r--r-- 1 root root 32 Apr 9 2019 api-model-1.0.0-sources.jar.md5
-rw-r--r-- 1 root root 40 Apr 9 2019 api-model-1.0.0-sources.jar.sha1
-rw-r--r-- 1 root root 57193 Apr 9 2019 api-model-1.0.0-test-sources.jar
-rw-r--r-- 1 root root 32 Apr 9 2019 api-model-1.0.0-test-sources.jar.md5
-rw-r--r-- 1 root root 40 Apr 9 2019
api-model-1.0.0-test-sources.jar.sha1
-rw-r--r-- 1 root root 170 May 26 09:25 maven-metadata.xml
-rw-r--r-- 1 root root 52 May 26 09:25 maven-metadata.xml.md5
-rw-r--r-- 1 root root 60 May 26 09:25 maven-metadata.xml.sha1
{noformat}
> not purging old versions higher than retention count
> ----------------------------------------------------
>
> Key: MRM-2014
> URL: https://issues.apache.org/jira/browse/MRM-2014
> Project: Archiva
> Issue Type: Bug
> Components: repository scanning
> Affects Versions: 2.2.4
> Environment: archiva 2.2.4
> ubuntu 16.04.6 LTS
> Reporter: Jason Grammenos
> Assignee: Martin Stockhammer
> Priority: Minor
> Attachments: archiva-02-redacted.png, archiva-redacted.xml,
> archiva_issue.png, archiva_issue1.png
>
>
> I have archiva configured with a retention count of 15.
> And days older of 0
> But archiva is not purging out old versions from some folders inside the
> repository.
> This appears to be a bug or there is something about how archiva is
> configured that would prevent it from removing those artifacts/versions.
>
> the repository purge consumer is enabled
> checking the logs, show that some purges where performed, but none have been
> performed in a log time.
>
> images attached of current config, and part of the a artifact showing more
> than 15 versions.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)