If you still need CentOS 4 and your yum is currently broken due to end-of-life, here’s the fix: Edit /etc/yum.repos.d/CentOS-Base.repo, comment out the mirrorlist parameters and add a baseurl=http://vault.centos.org/4.9/os/$basearch parameter for each enabled section. Here’s the official instructions: Using Vault Repositories