Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

I have a chroot environment in a directory. I want to install some RPM packages using the repositories in that chroot environment instead of the host OS ones.

yum --installroot= will look for packages repositories only in myroot/etc/yum.repos.d or it will only/also look in /etc/yum/repos.d? RHEL 6 is having the latter behavior. If that is expected behavior, what is the best method to achieve what I need?

Thanks in advance.

share|improve this question

I you start yum from within the chroot, it will only look in myroot/etc/yum.repos.d. If you start it from the normal system, it will always look in /etc/yum.repos.d.

So just start yum from within chroot. Of course you will first have to install yum and everything needed for it in the chroot.

share|improve this answer

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.