Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-20416

Artifactory fails to fetch metadata for RPM remote repository when metadata is corrupted

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: 6.13.0, 6.11.3
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Whenever the metadata for the RPM remote repository cache is corrupted, Artifactory fails to update the metadata from the remote endpoint and the yum client fails with the error "Metadata file does not match checksum". We tried setting the "Metadata retrieval cache period" to 0 and we expect that as this parameter is set to 0, Artifactory should be able to fetch the metadata every time a request comes but the request is not handled until and unless we delete the contents of the cache and perform zap cache. 

      We were able to reproduce the same behaviour by corrupting the metadata manually.

      These are the steps we followed,

      1. Create a remote repository "rpm-elastic" in Artifactory instance Art-1 which connects to https://artifacts.elastic.co/packages/
      2. Create a smart remote repository "rpm-smart-elastic" in other Artifactory instance Art-2 which points to "rpm-elastic" repository of Art-1.
      3. Configure the yum client to work with "rpm-smart-elastic" and we would be able to install and list the elasticsearch packages.

      Now to reproduce the issue,

      1. Created one local repository "rpm-local" in Art-2 and added the corrupted metadata files.
      2. Replicated the metadata files from "rpm-local" to "rpm-smart-elastic" repository, now the "rpm-smart-elastic" contains the corrupted metadata file in its cache.
      3. Once the files are replicated, we changed the remote endpoint of the smart remote repository "rpm-smart-elastic" to point to the "rpm-elastic" repository of Art-1.
      4. When we try to list or install the elasticsearch package using the yum client, it throws "Metadata file does not match checksum" instead of fetching the new metadata from Art-1's "rpm-elastic" repository.

      To work around the issue, we manually should clear the cache and perform zap cache so that Artifactory could get the new Metadata from the remote endpoint otherwise we can use the expirePackagesMetadata plugin.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                muhammedk Muhammed Kashif
              • Votes:
                1 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: