Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We've got a big batch of RHEL6 machines that are due for patching, and for some reason the process here does not involve a local repo. I'm new here, I've asked why, ["it just didn't work"] and I don't have enough time to make it work before the window that's already scheduled.

So the usual method is to install yum-downloadonly and run yum update --downloadonly --downloaddir=/mnt/cifs_share and then yum update /mnt/cifs_share/*.rpm which just does not look right to me since not all of these machines have the same set of installed packages.

The method I tried today was mounting the share to /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6/packages/ which worked, but then yum automatically deleted everything once it finished.

I've looked over the yum man page, but I don't see any flag I can feed it to stop it from deleting everything, nor a flag like up2date's --tmpdir=/mnt/cifs_share.

Can anyone out there help me kludge this together until I can get a local repository working?

share|improve this question
    
Can you just bring up a caching proxy server (squid?) quickly, and point yum at the proxy server? You will need to tweak it so it keeps the large package files, but it should be relatively easy. –  Zoredache Oct 31 '12 at 22:07
add comment

1 Answer

up vote 2 down vote accepted

Add this line to /etc/yum.conf:

keepcache=1

This will cause yum to leave the downloaded packages in place after installation.

share|improve this answer
add comment

Your Answer

 
discard

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.