I've run a yum update and get the below error:
Downloading packages:
scx-1.6.4-7.universal.x64.rpm FAILED
https://packages.microsoft.com/rhel/7/prod/scx-1.6.4-7.universal.x64.rpm: [Errno -1] Package does not match intended download. Suggestion: run yum --enablerepo=packages-microsoft-com-prod clean metadata
Trying other mirror.
Error downloading packages:
scx-1.6.4-7.x86_64: [Errno 256] No more mirrors to try.
I tried running the suggested command but it made no difference when I ran yum update again afterwards.
I've just encountered the same issue. Looks like Microsoft goofed something on that repo, I'm sure they'll eventually fix it. It happens from time to time on various repos.
To do the rest of the updates while excluding the Microsoft ones, try this:
yum clean all
yum clean metadata
yum makecache
yum update --disablerepo=packages-microsoft-com-prod
Note: The first 3 lines might not be necessary in your situation, however it does give a clean start point if you haven't done updates for a while.
Related
Recently installed Rocky Linux9 on a bunch of machines. No real problems except for some packages don't want to install.
Example: confluent-kafka-2.11. If I run dnf install confluent-kafka-2.11 -vv I get the usual downloading info but it ends with
Using rpmkeys executable at /usr/bin/rpmkeys to verify signatures
Problem opening package confluent-kafka-2.11-2.0.1cp8-1.noarch.rpm
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'yum clean packages'.
Error: GPG check FAILED
I've tried adding --nogpgcheck but it still doesn't work. What am I doing wrong?
Same problem with elasticsearch except I was able to manually install the gpg key. This won't work as soon as the package updates though.
There are multiple solutions here.
To actually solve the gpg issue, the question is, how did you add the repo and the gpg key?
What is the output of
sudo dnf list all | grep confluent
# and
sudo dnf repolist
My CentOS-Base.repo has the following mirrors:
[base]
name=CentOS-$releasever - Base
baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
enabled=1
#released updates
[updates]
name=CentOS Server updates
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
baseurl=http://custom-url/centOS-updates/
enabled=1
When I say yum install yum-utils, it fails with the error saying
http://custom-url/centOS-updates/Packages/yum-utils-1.1.31-46.el7_5.noarch.rpm: [Errno 14] HTTP Error 500 - Internal Server Error
Trying other mirror.
Error downloading packages:
yum-utils-1.1.31-46.el7_5.noarch: [Errno 256] No more mirrors to try.
I have two questions here:
Why is it looking at the `updates` repo instead of base. `yum info yum-utils` has the repo field set to `updates`. When I disable the `updates` repo in the repo file and do a `yum info yum-utils` it shows the repo field as `base` correctly. What decides the repo to look at given a package?
Why is 'Package' appended to the baseUrl when it tries to find yum-utils in the updates repo? This is causing a `500 Internal Server Error` as the path with Packages appended to it is invalid
A first-aid to internal server error from Yum is most likely a corrupt repodata on the remote server and/or mismatch cache between the client and server.
To wipe-clean the cache, use
$ yum --enablerepo=* clean all
or just this, if all the repos are enabled by default:
$ yum clean all
This does all the clean up available in yum. Here are what they do:
CLEAN OPTIONS
The following are the ways which you can invoke yum in clean mode. Note that "all files" in the commands below means "all files in currently enabled reposito‐
ries". If you want to also clean any (temporarily) disabled repositories you need to use --enablerepo='*' option.
yum clean expire-cache
Eliminate the local data saying when the metadata and mirrorlists were downloaded for each repo. This means yum will revalidate the cache for each repo.
next time it is used. However if the cache is still valid, nothing significant was deleted.
yum clean packages
Eliminate any cached packages from the system. Note that packages are not automatically deleted after they are downloaded.
yum clean headers
Eliminate all of the header files, which old versions of yum used for dependency resolution.
yum clean metadata
Eliminate all of the files which yum uses to determine the remote availability of packages. Using this option will force yum to download all the metadata
the next time it is run.
yum clean dbcache
Eliminate the sqlite cache used for faster access to metadata. Using this option will force yum to download the sqlite metadata the next time it is run,
or recreate the sqlite metadata if using an older repo.
yum clean rpmdb
Eliminate any cached data from the local rpmdb.
yum clean plugins
Tell any enabled plugins to eliminate their cached data.
yum clean all
Does all of the above.
mysqlclient is not installing in centos 7 and I attached the image where errors are shown so that you take idea from that. Your help is very appreciable for me.
Edit1 : #Jose
I tried your steps but at the very first step I get the following error:
Error downloading packages:
mysql-community-devel-5.6.36-2.el7.x86_64: [Errno 5] [Errno 2] No such file or directory
mysql-community-libs-5.6.36-2.el7.x86_64: [Errno 5] [Errno 2] No such file or directory
mysql-community-common-5.6.36-2.el7.x86_64: [Errno 5] [Errno 2] No such file or directory
Please tell me why?
ok, let's check possible issues step by step. The problem could be related to connectivity issues, broken packages, a broken rpm repository, or a problem with the mirrors used to download packages. Here are the things to look for:
So first thing we need to check is whether the internet connection is working fine. I'm not convinced this is the real issue, since based your comments it seems you were actually able to other packages, but you never know. Try pinging the DNS server for Google (ping 8.8.8.8) or curling the google website (curl www.google.com). If those things work, move on to the next step, otherwise we need to troubleshoot network service configuration.
If the internet connection is working fine, we need to investigate broken packages:
Run the following commands to clear up your yum cache: sudo yum clean all, sudo yum clean headers, and sudo yum-complete-transaction, then try to install your package again. If still doesn't work, move on to the next step.
Can yum tell us about problem with certain packages? Run package-cleanup --problems. If it shows problems, please update your question with the report. Otherwise move on the the next step.
It's possible that some installation you made in the past made things go wrong. Do yum history and see if you can spot the step where everything went wrong, and use the ID to remove that step by running sudo yum history undo <ID>. Try installing your package now. If that doesn't work, move on to the next step.
Try reinstalling all packages: sudo yum reinstall \*. If that works, try to install your package now, otherwise paste the error in your question.
If all of your packages are fine, we need to investigate issues with rpm.
Try rebuilding your rpm database: sudo rpm --rebuilddb and then try to install again your package.
Please let me know if none of this works, and I'll update the answer.
How do I disable yum transaction check for a file ?
Transaction check error:
file /usr/local/xenco/backend/current from install of xenco-rr-1.9.6-104.x86_64 conflicts with file from package xenco-server-1.9.6-104.x86_64
Replacing files from another RPM package is bad idea in most cases and I strongly advise against what you're trying to do. That said, apply following at your own risk.
Yum does not provide an option to install conflicting files, I think. However, that does not prevent you from installing a RPM package with rpm(1) which does provide an option to override existing files from another package, namely --replacefiles.
So, first get the RPM of the package you want to install on a local filesystem (/usr/local/xenco... makes me suspect that is the case already). Next install the RPM with rpm -i --replacefiles <your_rpm_file>.
This method worked for me, when I faced similar issue
Simply get the existing package with below command
rpm -qa | grep xenco
Remove those conflicting package with
yum remove packageNameFromTheList
what i always do is remove the package that is on the right hand side. In your case it would be -
yum remove xenco-server-1.9.6-104.x86_64
yum remove <> can work with any package error, i have encountered many such transactions errors when working on vm on cloud, i always remove the package that causes conflicts and always has worked for me.
My two cents:
yum erase ${old_package}
yum install ${new_package_with_same_files}
The exclusion of --replacefiles is intentional. Yum is a package manager, let it manage the packages.
(This answer adds a yum-only solution to the accepted answer.)
I am trying to isntall something using "yum install my.rpm"
The problem is I am getting
TypeError: an integer is required
error: python callback <bound method RPMTransaction.callback of <yum.rpmtrans.RPMTransaction instance at 0x013e3f8>> failed, aborting!
What does this mean? I turned on verbosity of the yum install, cant figure anything out. This is RHEL 6.1
Thanks
If rpm is not able to access the file for some reason while installing the package, it throws this error.
For example if your rpm is located on a NFS share witn root_squash directive, and try to install, then since root while attempting to access the file won't be permitted to it will fail, and it throws this excact error.
If this is your case, then putting the rpm in something like /tmp first, and then re-trying will solve it.
To install a rpm file with yum, you need to use the localinstall command:
localinstall
Is used to install a set of local rpm files. If required the enabled repositories will be used to resolve dependencies. Note that
the install command will do a local install, if given a filename.
For example "yum localinstall my.rpm". But I think you also have a problem with your spec file.