Bobcares

YUM error performing checksum : How we correct it?

by | Dec 16, 2019

Are you struggling with YUM error performing checksum?

Occasionally while installing a package or updating using YUM command ends up in this error.

The error is usually generated when the checksum algorithm specified in the repository file will not support the yum version.

At Bobcares, we often get requests to fix yum errors, as a part of our Server Management Services.

Today, let’s have a quick look at reasons for the occurrence of this error. We’ll also see how our Support Engineers fix the error performing checksum.

 

Why yum error performing checksum?

Yum stands for Yellowdog Updater, Modified. YUM is a program that manages installation, updates, and removal for Red Hat package manager (RPM) systems.

A checksum is a small-sized datum assigned to any file for the purpose of detecting errors. In other words, when the file goes corrupt, the checksum may not match. Thus it indicates an error.

Generally, yum error performing checksum occurs when we install or update a new package using yum.

The error message appears as:

yum error performing checksum

Often the error happens when installing packages that do not match the server architecture.

The error has been identified when yum update on a Centos5 or RHEL5 box, using RPMs from a repository on a CentOS6 or RHEL6 server (or anywhere else with a more modern createrepo available). Createrepo is a program that creates a repomd (xml-based rpm metadata) repository from a set of RPMs.

In simple words, from the error, it’s clear that the yum is unable to calculate the sha256 checksum. This happens due to the necessary libraries not available for yum to calculate the new checksum correctly.

Let, see how our support engineers help to fix this problem by various methods.

 

Different methods to fix yum error performing checksum!

At Bobcares, where we have more than a decade of expertise in managing servers, we see many customers face problems with the yum error performing checksum.

Now, let’s see the major reasons for this error and how our Support Engineers fix this error by different methods.

 

1. Installing python-hashlib

Python 2.6 uses hashlib to perform checksums whereas  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, that is why we get the checksum error.

Recently, one of the customers had a problem with yum error performing checksum while installing a package using the yum. Installing the python-hashlib package help to add SHA256 capabilities. Therefore our Support Engineers fixed the error by installing python-hashlib to resolve this problem.

yum install python-hashlib

After installing python-hashlib, SHA256 algorithm worked with Yum command. This fixed the error.

 

2. Removing offending repo

In addition, some customers returned to us with the following error while installing the python-hashlib.

yum install python-hashlib
Loaded plugins: downloadonly-background, fastestmirror, ibm-check-lotus-updates, ibm-repository, refresh-packagekit, security, versionlock
Loading mirror speeds from cached hostfile
Setting up Install Process
Package python-2.6.6-29.el6_3.3.x86_64 already installed and latest version
Nothing to do
[root@xxx ~]#

After further investigations, we found that there was some offending repo created. We disabled some offending repo before installing python-hashlib.

We did the following steps:

1. Initially, we opened the following configuration file and set the enable variable to 0

/etc/yum.repos.d/newNotWorking.repo
enabled=0

2. Then after editing this file, we installed the python-hashlib.

yum install python-hashlib

3. Finally, we re-enabled the new repo

enabled=1

And this fixed the error.

 

3. Create the repo using sha1

However, in certain situations, where the customer was using a custom repository made by a newer version of “createrepo” causes the same error. Here the repodata checksum had generated with sha256, which was not supported by yum in Centos 5. This leads the customer with the following error:

https://some-repository.com/repodata/6bf3eabf71186292f5559891e9161887b45a647318499e1b0e3b05d6b6e4f62b-primary.sqlite.bz2:
[Errno -3] Error performing checksum

Hence, we re-generated the repo metadata with sha1 checksum by using the following command.

createrepo -d -s sha1 /path/to/repo

After creating repo metadata with sha1, made everything worked as expected

 

4. Disable epel

The checksum error can happen even with the error in the epel repository. In such cases, an immediate fix is to disable the epel repo.

We can disable either via editing the file as enable=0 or else rename the file. Here we disabled it by renaming the file.

mv /etc/yum.repos.d/epel{,.bak}
yum clean all

We have fixed this error of many customers by disabling epel.

5. Reinstall package

Last, but not the least, often reinstalling the package also can solve the yum error performing checksum. Here, with the reinstall, all the files will be overwritten with the correct files.

[Still having trouble in fixing yum errors? – We’ll help you.]

 

Conclusion

In short, yum error performing checksum occur due to many reasons. The most common reasons are an unsupported repository with yum version, yum cache and so on. Today, we saw how our Support Engineers fixed this error.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

var google_conversion_label = "owonCMyG5nEQ0aD71QM";

0 Comments

Submit a Comment

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

Never again lose customers to poor
server speed! Let us help you.

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie
_clck, _clsk, CLID, ANONCHK, MR, MUID, SM

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

_reb2bgeo - The visitor's geographical location

_reb2bloaded - Whether or not the script loaded for the visitor

_reb2bref - The referring URL for the visit

_reb2bsessionID - The visitor's RB2B session ID

_reb2buid - The visitor's RB2B user ID

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid
_reb2bgeo, _reb2bloaded, _reb2bref, _reb2bsessionID, _reb2buid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF