12

This is a set up I am doing for a college to promote Linux use in their labs.

I have a shared location, let me call it /tp; I want to install all my libraries and packages in this location just like the default install. Reason to do this is: I want all the users in the network connected to this server to link their programs to this particular location to pick up libraries for the program.

The closest I came to was using (for example) yum install boost --installroot=/tp/. This did not work as the yum started looking for mirror list in this location. I want the installation to be done in the location /tp/

3

the installroot tool is usefull for situations like installing packages into a chroot environment. try installing all the yum configuration and repo files into /tp, keeping their respective paths, and your custom package installation will work. (eg: /tp/etc/yum.conf).

in such a case /tp will be prepended to any files that are read or written by yum. that includes configurations files, yum log files, repository information, etc.

3

From the rpm man page:

   --prefix NEWPATH
          For relocatable binary packages, translate all file  paths  that
          start  with  the  installation  prefix in the package relocation
          hint(s) to NEWPATH.

   --relocate OLDPATH=NEWPATH
          For relocatable binary packages, translate all file  paths  that
          start with OLDPATH in the package relocation hint(s) to NEWPATH.
          This option can be used repeatedly if several OLDPATH's  in  the
          package are to be relocated.
  • 4
    --prefix does not seem to exist w/ yum (at least on CentOS 6.4 x64) – Doktor J Mar 11 '14 at 23:35
  • 2
    The answer says this is for rpm, not yum. – Mark Lakata Dec 2 '15 at 2:50
0

You could just chroot /tp/ to change your root into that location. Then re-try you yum installation.

This is common for LIVEOS, say for prototype/test run requiring large package installation, whereas the pre-designed RAMDISK is allocated small in that particular location.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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