[Hampshire] Installing software into a mounted partition

Top Page

Reply to this message
Author: James Courtier-Dutton
Date:  
To: Hampshire LUG Discussion List
Subject: [Hampshire] Installing software into a mounted partition
Hi,

In Linux, I would like to be able to mount a partition and then
install software into that partition.
The problem is that I do not wish to run any of the executables in the
partion so chroot is not an option.

I.e.
aptitude install firefox --destination_root=/mnt/sdc1

So, this should update the package indexes etc on the /mnt/sdc1 partition.
The main use of this is so that I could create a ARM or MIPS Linux OS
partition from a x86 machine and be able to easily add and remove
packages from the destination partition.
I think the problem with this will be the post-install scripts inside
each .deb package are not necessarily CPU agnostic.
It might also be useful for provisioning virtual machines without
actually having to run the virtual machine.
I have other possible uses for this feature. For example, be able to
walk up to a PC, boot a CD, and force the Linux install to a specific
mix of packages installed.
I.e. It would automatically remove unwanted packages and install new
updated ones. The use of a CD is because the PC might not have an
internet or network connection.

Does anyone know of a way round this problem?

Another example of the problem is say, one has a 32 bit Linux OS
installed, one cannot run debootstrap to install a 64bit OS.
One has to instead boot into a 64bit Linux OS before one can
debootstrap to install a 64bit OS onto the target partition.

Kind Regards

James