Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Debian's apt-get update fetches and updates the package index. Because I'm used to this way of doing things, I was surprised to find that yum update does all that and upgrades the system. This made me curious of how to update the package index without installing anything.

share|improve this question
up vote 45 down vote accepted

The check-update command will refresh the package index and check for available updates:

yum check-update
share|improve this answer

While "yum check-update" will refresh the local cache, if it needs to be refreshed, so will most other commands.

The command that's strictly the equivalent of "apt-get update" is "yum makecache" ... however it's generally not recommended to run that directly, in yum.

share|improve this answer
I don't understand the first sentence. Can you rephrase maybe? – Tshepang Feb 8 '11 at 18:06
It means that other yum commands, e.g. yum upgrade will automatically run yum check-update if necessary. In other words, yum upgrade is basically the same as apt-get update; apt-get upgrade. – Mikel Feb 8 '11 at 21:02
Thank you! yum check-update did not helps me against 404 errors. But yum makecache helps! HUGE thanks! – socketpair Jun 6 '14 at 11:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.