Learning and Sharing
  • Home
  • Blog
  • Linux
  • macOS
  • Virtualization
    • VMware
    • VirtualBox
  • Windows
    • Windows 11
    • Windows 10
    • Windows Server
  • Series
    • Symantec
    • Intune
    • Microsoft Azure
    • Powershell
    • VirtualBox
    • VMware
    • PowerShell Learning
    • Microsoft Graph
  • More
    • Auto Installation
    • AEC Installation
  • Contact
No Result
View All Result
  • Home
  • Blog
  • Linux
  • macOS
  • Virtualization
    • VMware
    • VirtualBox
  • Windows
    • Windows 11
    • Windows 10
    • Windows Server
  • Series
    • Symantec
    • Intune
    • Microsoft Azure
    • Powershell
    • VirtualBox
    • VMware
    • PowerShell Learning
    • Microsoft Graph
  • More
    • Auto Installation
    • AEC Installation
  • Contact
No Result
View All Result
No Result
View All Result

Errors During Downloading Metadata for Repository Appstream

May 1, 2023
in Blog, Linux
0
ADVERTISEMENT

Table of Contents

Errors During Downloading Metadata for Repository Appstream

In this post, we will take you through the steps to solve Failed to download metadata for repo AppStream error which I was getting in a CentOS 8 Server.

This problem can be encountered in any of the CentOS 8 system which is still in use post December 31st, 2021. The reason is because CentOS 8 had already reached its End of Life (EOL) on this date which means that it will no longer receive any development updates from official CentOS Project.

But if you are still thinking to use or already using this OS after Dec 31st, 2021 due to any reason then you need to change the mirror to Vault where it will be archived permanently like it happened for other older CentOS versions.

[bonben@centos8 ~]$ sudo dnf update -y
CentOS Linux 8 - AppStream                                                                           26 kB/s | 8.1 kB     00:00
Errors during downloading metadata for repository 'appstream':
  - Status code: 404 for http://mirror.centos.org/centos/8/AppStream/x86_64/os/repodata/repomd.xml (IP: 204.15.73.245)
Error: Failed to download metadata for repo 'appstream': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
CentOS Linux 8 - BaseOS                                                                              41 kB/s | 8.1 kB     00:00
Errors during downloading metadata for repository 'baseos':
  - Status code: 404 for http://mirror.centos.org/centos/8/BaseOS/x86_64/os/repodata/repomd.xml (IP: 69.4.80.162)
Error: Failed to download metadata for repo 'baseos': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
Ignoring repositories: appstream, baseos 

To fix the above error, we need to change the repo URL pointing from official CentOS URL to vault.centos.org using below commands.

sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
sed -i 's/mirrorlist/mirrorlist/g' /etc/yum.repos.d/CentOS-*
sed -i 's|baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*

Alternatively, you can also point to the Cloudflare-based vault repository, by running the following commands:

sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-*
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.epel.cloud|g' /etc/yum.repos.d/CentOS-Linux-*
sed -i 's/mirrorlist/mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-*
sed -i 's|baseurl=http://mirror.centos.org|baseurl=http://vault.epel.cloud|g' /etc/yum.repos.d/CentOS-Linux-*

Once the mirror is changed and updated, we can now try to update again by using dnf update or yum update command as shown below. This time it works fine as expected.

[root@centos8 ~]# yum update -y
CentOS-8 - AppStream                                                                     28 MB/s | 8.4 MB     00:00
CentOS-8 - Base                                                                          13 MB/s | 4.6 MB     00:00
CentOS-8 - Extras                                                                       165 kB/s |  10 kB     00:00
CentOS-8 - PowerTools                                                                   5.3 MB/s | 2.3 MB     00:00
Extra Packages for Enterprise Linux Modular 8 - x86_64                                   13 kB/s | 9.6 kB     00:00
Extra Packages for Enterprise Linux Modular 8 - x86_64                                   23 kB/s | 733 kB     00:32
Extra Packages for Enterprise Linux 8 - x86_64                                          8.3 kB/s | 9.1 kB     00:01
Extra Packages for Enterprise Linux 8 - x86_64                                          808 kB/s |  13 MB     00:16
Dependencies resolved.
========================================================================================================================
 Package                             Architecture Version                                        Repository        Size
========================================================================================================================
Installing:
 centos-linux-release                noarch       8.5-1.2111.el8                                 BaseOS            22 k
     replacing  centos-release.x86_64 8.2-2.2004.0.1.el8
     replacing  centos-repos.x86_64 8.2-2.2004.0.1.el8
 kernel                              x86_64       4.18.0-348.7.1.el8_5                           BaseOS           7.0 M
 kernel-core                         x86_64       4.18.0-348.7.1.el8_5                           BaseOS            38 M
 kernel-modules                      x86_64       4.18.0-348.7.1.el8_5                           BaseOS            30 M
5/5 - (1 vote)
Previous Post

How to Install CyberPanel on Centos 8 Linux

Next Post

Errors During Downloading Metadata for Repository Baseos on CentOS 8 Linux

Related Posts

Running Hyper-V and VMware Workstation on The Same Machine

August 15, 2024

How to Uninstall All Autodesk Products At Once Silently

July 29, 2024
Ftr5

How to Uninstall the Autodesk Genuine Service on Windows

July 29, 2024
Ftr19

How to Fix Windows Cannot Read the ProductKey From the Unattend Answer File in VirtualBox

July 26, 2024
Ftr25

How to Update Windows Terminal in Windows 10/11

July 26, 2024

How to Disable The Beep Sound in WSL Terminal on Windows

July 26, 2024

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recent Posts

  • How To Turn On uBlock Origin Extension in Chrome (2025)
  • Images Hidden Due To Mature Content Settings In CivitAI
  • Azure OpenAI vs Azure AI Hub, How to Choose the Right One for Your Needs

Categories

Stay in Touch

Discord Server

Join the Discord server with the site members for all questions and discussions.

Telegram Community

Jump in Telegram server. Ask questions and discuss everything with the site members.

Youtube Channel

Watch more videos, learning and sharing with Leo ❤❤❤. Sharing to be better.

Newsletter

Join the movement and receive our weekly Tech related newsletter. It’s Free.

General

Microsoft Windows

Microsoft Office

VMware

VirtualBox

Technology

PowerShell

Microsoft 365

Microsoft Teams

Email Servers

Copyright 2025 © All rights Reserved. Design by Leo with ❤

No Result
View All Result
  • Home
  • Linux
  • Intune
  • macOS
  • VMware
  • VirtualBox
  • Powershell
  • Windows 10
  • Windows 11
  • Microsoft 365
  • Microsoft Azure
  • Microsoft Office
  • Active Directory

No Result
View All Result
  • Home
  • Linux
  • Intune
  • macOS
  • VMware
  • VirtualBox
  • Powershell
  • Windows 10
  • Windows 11
  • Microsoft 365
  • Microsoft Azure
  • Microsoft Office
  • Active Directory