?
Solved

Kickstart installation - adding commands available at 'pre' time

Posted on 2004-08-10
2
Medium Priority
?
500 Views
Last Modified: 2013-12-15
I'm currently building a kickstart cd, and it's all ready to go except...the script I'm using in the 'pre' section needs to commands (bc and expr), that arn't available by default in the stage2.img file.
Everything I've read tells me to just mount the file, add the commands I need, and all will be fine.
Whilst I can mount the img file, it appears to be mounted in a read-only mode, so whenever I try and add the commands to it, I'm just getting the 'permission denied' error:

# mount -o loop stage2.img j
# touch j/test
touch: creating `j/test': Permission denied
# umount j
# mount --o loop,rw stage2.img j
# touch j/test
touch: creating `j/test': Permission denied
#

mount does show the image file being mounted read/write:
/tmp/j/stage2.img on /tmp/j/j type cramfs (rw,loop=/dev/loop0)

Anyone got any bright ideas on how to add these commands to the img file?
500 points on offer, 'coz my new servers are due to arrive in about 3 hours or so, and I want to start getting linux installed as soon as possible!
0
Comment
Question by:j_dyer
2 Comments
 
LVL 6

Accepted Solution

by:
de2Zotjes earned 2000 total points
ID: 11761369
Cramfs file systems are read only by nature.

There is a tool mkcramfs that creates a cramfs file.

What you would do is mount the original image. Copy the contents to an empty subdir elsewhere in the dir-tree. Add the stuff you want in the image and then mkcramfs <subdir> <filename>
0
 
LVL 2

Author Comment

by:j_dyer
ID: 11762998
Thanks for the fast response - worked fine.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Fine Tune your automatic Updates for Ubuntu / Debian
I have written articles previously comparing SARDU and YUMI.  I also included a couple of lines about Easy2boot (easy2boot.com).  I have now been using, and enjoying easy2boot as my sole multiboot utility for some years and realize that it deserves …
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month14 days, 2 hours left to enroll

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question