This is exactly what has been perplexing me. I want to add to the iso, but the filepaths within install.img do not replicate the ones on Fedora. Within /etc for instance there is no yum.repos.d directory. Can I just make that directory and add for instance, rpmfusion repos? Can I just stick my own backgrounds into /usr/share/backgrounds? Thanks, Kurt
Perform an inception. Mount the install img from inside an iso to see whats available in kickstart pre installs
Mount your iso, then mount the image found inside and change it
First you’ll need to mount your distribution iso image.
|
1 |
# mount -o loop Fedora-13-x86_64-DVD.iso /mnt/level1 |
Go inside the distribution iso where you mounted it under /mnt/level1 and you should see an images directory with the install.img inside it. Images is at the same level as isolinux.

We have to go deeper
Mount that stage one image somewhere else. You should be able to mount it to another directory from where it’s already mounted at level1 itself, but if not, rsync is your friend. Just copy it somewhere else before you try to mount it.
|
1 |
# mount -o loop images/install.img /mnt/level2 |
Here’s what you have available during stage one right out of the box from a Fedora 13 DVD iso.
|
1 2 3 4 5 6 7 8 9 10 |
# ls -l /mnt/level2/ total 0 drwxr-xr-x. 20 root root 495 2010-08-24 10:52 etc drwxr-xr-x. 2 root root 3 2010-08-24 10:52 firmware drwxr-xr-x. 4 root root 74 2010-08-24 10:52 lib drwxr-xr-x. 4 root root 2897 2010-08-24 10:48 lib64 drwxr-xr-x. 2 root root 3 2010-08-24 10:52 modules drwxr-xr-x. 2 root root 3 2010-08-24 10:52 proc drwxr-xr-x. 9 root root 149 2010-08-24 10:52 usr drwxr-xr-x. 5 root root 50 2010-08-24 10:40 var |
Inception Time
Now if you have an iso editor such as isomaster, you could rebuild the install.img and plop that inside the the outer iso, rebuilding that one too.
Need more libraries? Don’t like anaconda’s jpg/png’s? Add them in there and rebuild the install image using mksquashfs , then drop it in your distro image, and rebuild that using isomaster .
This has been oversimplified on purpose to keep it short and sweet. Don’t forget, you’re stuck with read-only file systems when you mount images with loopback, so you’ll need to copy the contents elsewhere and rebuild them.
Of course, an easier way to get the job done might just be to use a different set of commands if you find whatever it was you were hoping would be available during %pre install is missing.
For example, No fdisk? Try sfdisk or parted instead.

This is exactly what has been perplexing me. I want to add to the iso, but the filepaths within install.img do not replicate the ones on Fedora. Within /etc for instance there is no yum.repos.d directory. Can I just make that directory and add for instance, rpmfusion repos? Can I just stick my own backgrounds into /usr/share/backgrounds? Thanks, Kurt