Primary.xml.gz Error Performing Checksum
Contents |
I tried to apply the latest CentOS 5.3 updates to one of my servers last week, I noticed that I was getting a number of "Error performing checksum" errors: yum errno 3 error performing checksum $ yum repolist Loaded plugins: fastestmirror Determining fastest mirrors Updates | 1.2 kB yum ignore checksum 00:00 primary.xml.gz | 376 kB 00:00 http://updates/repo/centos/5.3/updates/repodata/primary.xml.gz: [Errno -3] Error performing checksum Trying other mirror. primary.xml.gz | 376 kB 00:00 yum metadata does not match checksum http://updates/repo/centos/5.3/updates/repodata/primary.xml.gz: [Errno -3] Error performing checksum Trying other mirror. Error: failure: repodata/primary.xml.gz from Updates: [Errno 256] No more mirrors to try. After reading through the code in yumRepo.py, I noticed that the error python-hashlib rpm listed above is usually generated when the checksum algorithm specified in the repomd.xml file isn't supported. The createrepo utility uses the sha256 algorithm by default in Fedora 11 (I created my repositories on a Fedora 11 host), so I decided to create my repository using the sha1 algorithm instead: $ createrepo -v -s sha1 /var/www/html/repo/centos/5.3/updates Once I created the repository metadata using the sha1 algorithm, everything
Yum Disable Checksum Check
worked as expected: $ yum clean all Loaded plugins: fastestmirror Cleaning up Everything Cleaning up list of fastest mirrors $ yum repolist Loaded plugins: fastestmirror Determining fastest mirrors Updates | 1.0 kB 00:00 primary.xml.gz | 367 kB 00:00 Updates 634/634 repo id repo name status Updates Updates enabled : 634 repolist: 634 This debugging experience made me realize two things: 1. Having your package manager written in Python makes debugging super easy 2. Python 2.6 uses hashlib to perform checksums, and Python 2.4 uses the SHA module to perform checksums. The version of the SHA module that ships with CentOS 5.3 doesn't support sha256, which is why we get the checksum error listed above. I had a h00t debugging this issue, and am glad everything is working correctly now! Nice! matty on November 26, 2009 | Filed Under Linux Debugging, Linux Package Management 10 Comments Fouad on March 22nd, 2010 Thanks I really tried to make a local repo on RHEL5 and it didn't work but after I did as you what said. Emmett O'Grady on April 16th, 2010 Thanks for this blog! Spent quite a bit of time looking before I found this! I was
Red Hat Certificate System Red Hat Satellite Subscription Asset Manager Red Hat Update Infrastructure Red Hat Insights Ansible Tower by Red Hat Cloud Computing Back Red Hat CloudForms Red Hat OpenStack Platform Red
[errno -1] Metadata File Does Not Match Checksum
Hat Cloud Infrastructure Red Hat Cloud Suite Red Hat OpenShift Container Platform Red [errno -3] error performing checksum Hat OpenShift Online Red Hat OpenShift Dedicated Storage Back Red Hat Gluster Storage Red Hat Ceph Storage JBoss Development and Management yum makecache error performing checksum Back Red Hat JBoss Enterprise Application Platform Red Hat JBoss Data Grid Red Hat JBoss Web Server Red Hat JBoss Portal Red Hat JBoss Operations Network Red Hat JBoss Developer Studio JBoss Integration and http://prefetch.net/blog/index.php/2009/11/26/dealing-with-yum-checksum-errors/ Automation Back Red Hat JBoss Data Virtualization Red Hat JBoss Fuse Red Hat JBoss A-MQ Red Hat JBoss BPM Suite Red Hat JBoss BRMS Mobile Back Red Hat Mobile Application Platform Services Back Consulting Technical Account Management Training & Certifications Red Hat Enterprise Linux Developer Program Support Get Support Production Support Development Support Product Life Cycle & Update Policies Knowledge Search Documentation Knowledgebase Videos Discussions Ecosystem Browse Certified https://access.redhat.com/solutions/2047453 Solutions Overview Partner Resources Tools Back Red Hat Insights Learn More Red Hat Access Labs Explore Labs Configuration Deployment Troubleshooting Security Additional Tools Red Hat Access plug-ins Red Hat Satellite Certificate Tool Security Back Product Security Center Security Updates Security Advisories Red Hat CVE Database Security Labs Resources Overview Security Blog Security Measurement Severity Ratings Backporting Policies Product Signing (GPG) Keys Community Back Discussions Red Hat Enterprise Linux Red Hat Virtualization Red Hat Satellite Customer Portal Private Groups All Discussions Start a Discussion Blogs Customer Portal Red Hat Product Security Red Hat Access Labs Red Hat Insights All Blogs Events Customer Events Red Hat Summit Stories Red Hat Subscription Benefits You Asked. We Acted. Open Source Communities Subscriptions Downloads Support Cases Account Back Log In Register Red Hat Account Number: Account Details Newsletter and Contact Preferences User Management Account Maintenance My Profile Notifications Help Log Out Language Back English español Deutsch italiano 한국어 français 日本語 português 中文 (中国) русский Customer Portal Search Products & Services Back View All Products Infrastructure and Management Back Red Hat Enterprise Linux Red Hat Virtualization Red Hat Identity Management Red Hat Directory Server Red Hat Certificate System Red Hat Satellite Subscription Asset Manager Red Hat Update Infr
-3] Error performing checksum Issues related to software problems. Post Reply Print view Search Advanced search 3 http://www.centos.org/forums/viewtopic.php?t=21344 posts • Page 1 of 1 chenry Posts: 1 Joined: 2010/09/02 14:31:02 yum error [Errno -3] Error performing checksum Quote Postby chenry » 2010/09/02 15:23:08 Hi,I'm trying to create a local yum repo. I've followed the instructions here. I've got the 'updates' repo working fine and have updated the server which is error performing having the error fine, but the 'base' repo gives the following error:Code: Select all[root@server ~]# [b]yum list updates[/b]
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* addons: mirror.sov.uk.goscomb.net
* base: mirror.sov.uk.goscomb.net
* extras: mirror.sov.uk.goscomb.net
* updates: mirror.ukhost4u.com
base-local/primary | 1.2 MB 00:00
http://192.168.0.53/repo/centos/5.5/base/x86_64/CentOS/repodata/primary.xml.gz: [Errno -3] Error performing checksum
Trying other error performing checksum mirror.
Error: failure: repodata/primary.xml.gz from base-local: [Errno 256] No more mirrors to try.
[root@server ~]#I used gthe following command to create the 'base' repo:Code: Select allcreaterepo /var/www/html/repo/centos/5.5/base/x86_64/CentOS/The repo (local.repo) file has the following contents:Code: Select all[base-local]
name=Centos $releasever - $basearch
failovermethod=priority
baseurl=http://192.168.0.53/repo/centos/5.5/base/x86_64/CentOS/
enabled=1
gpgcheck=0
[updates-local]
name=Centos $releasever - $basearch - Updates
failovermethod=priority
baseurl=http://192.168.0.53/repo/centos/5.5/updates/x86_64/
enabled=1
gpgcheck=0
If I change the enabled=1 to enabled=0 the updates work fine. I can browse to and download the primary.xml.gz file using a browser, so it seems to have the correct permissions:Code: Select all[root@repo ~]# [b]ll /var/www/html/repo/centos/5.5/base/x86_64/CentOS/repodata/[/b]
total 6544
-rw-r--r--. 1 root root 3717874 2010-09-02 14:54 filelists.xml.gz
-rw-r--r--. 1 root root 1719201 2010-09-02 14:54 other.xml.gz
-rw-r--r--. 1 root root 1254316 2010-09-02 14:54 primary.xml.gz
-rw-r--r--. 1 root root 1375 2010-09-02 14:54 repomd.xml
[root@repo ~]#The /etc/yum.repos.d directory has the following:Code: Select all[root@server ~]# [b]ll /etc/yum.repos.d/[/b]
total 24
-rw-r--r-- 1 root root 2245 Apr 26 00:25 CentOS-Base.repo
-rw-r--r-- 1 root root 626 Apr 2