jds5
Posts: 1
Joined: Tue Feb 23, 2016 11:27 pm

Installing software into a non-running system

Tue Feb 23, 2016 11:49 pm

Hi There,
Im looking for some advice on a way to install some software on my offline Rpi.

I had the thought - don't Linux CD installers run out of RAM and install packages onto a non-running system? (ie the just formatted hard drive)
So I was thinking about taking the SD card out of the Pi, to another linux machine on the internet, (x86, but I would have to use the Rpi repositories) and can you use apt-get (or another package manager) to unpack Rpi packages into the attached Rpi linux file system rather than the running system?

Is that possible? how do Linux installers do it? Whenever I search on it, it's too generic so comes up with how to install packages on the system you are running, rather than into another linux filesystem.

I have looked at apt-offline, but that seems to be updating a whole system, and I was looking for more granularity about installing just a few new packages. (and different packages for each Pi I have)

Any ideas would be helpful.
Thanks
J.

ghans
Posts: 7882
Joined: Mon Dec 12, 2011 8:30 pm
Location: Germany

Re: Installing software into a non-running system

Wed Feb 24, 2016 8:47 am

Its called chroot (change root).

Try "Plan B" outlined in this blogpost :
http://sentryytech.blogspot.de/2013/02/ ... berry.html

Also :
Alistair Buxton November 7, 2013 at 12:06 AM wrote:
From: http://xecdesign.com/qemu-emulating-ras ... -easy-way/

You need to edit /etc/ld.so.preload in the image and comment out the one and only line with a #.


ghans
• Don't like the board ? Missing features ? Change to the prosilver theme ! You can find it in your settings.
• Don't like to search the forum BEFORE posting 'cos it's useless ? Try googling : yoursearchtermshere site:raspberrypi.org

fsr
Posts: 88
Joined: Wed Jan 13, 2016 2:29 am

Re: Installing software into a non-running system

Wed Feb 24, 2016 9:12 am

jds5 wrote:don't Linux CD installers run out of RAM and install packages onto a non-running system
no, the system is definitely running. it just booted of the cd instead of the HD
jds5 wrote:how do Linux installers do it?
The new root is mounted in a temporary location and built.
The package manager is told to use an alternate root path and it updates (the running) OS onto the HD
jds5 wrote:x86, but I would have to use the Rpi repositories
things start getting mighty messy with mixed architectures...
I mean what you are asking is possible but compared to plugging in a wifi dongle its just not even worth considering it.

Back in the old days machines without NICs were updated manually (download packages, plug into computer, update - ^&^$ need packageabc123 too, download more packages, plug into computer, repeat rinse wash).
You don't want to go back there. :)

Return to “General discussion”