I was tired of burning copies of Linux distribution CDs only to throw them away when the next revision came around. With copies for home, and copies for work it gets to be pretty wasteful. So I decided to take my latest Mandrake 9.2 CDs and create ISO images from them which I could then store on my hard drive. Once the ISO image is on your hard drive you can mount it like any other file system and use it.
First you will need a directory to store all those ISOs, and depending on how many CDs you want to copy it could require quite a bit of space. The latest Mandrake set comes on seven discs! I prefer a root level directory for my ISOs:
mkdir /iso
Then place the CD you want to copy into the CD drive and start copying:
dd if=/dev/cdrom of=/iso/mandrake-9.2-install_1.iso
This could take a while, so you should probably have something else handy to do while you wait. Repeat the steps for each CD you want to copy.
Next create a directory to mount each individual ISO onto:
mkdir /mnt/iso chmod 555 /mnt/iso/
Now you may mount and un-mount the ISO like so:
mount -o loop,ro -t iso9660 /iso/mandrake-9.2-install_1.iso /mnt/iso umount /mnt/iso
Once mounted you may navigate and use it like any other file system.
This next section involves updating URPMI sources and is thus Mandrake specific, but other package management systems are probably similar.
To be able to use your CDs for installing packages through URPMI you will need to update where the sources point to by changing them from:
removable://mnt/cdrom/Mandrake/RPMS
to:
removable://mnt/iso/Mandrake/RPMS
The next step is to make sure the hdlist.cz file location is in fact correct. Finding the correct relative path is not hard to find on the image, it just takes a bit of looking.
Now when you need to install something just mount the ISO, and you are good to go.
Dude. You’re not dead or anything. Yaaayy!