Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to add a tar archive in the standard Red Hat installation CD image and untar the same at a desired location using some post install scripts.

Can you kindly suggest me how to proceed? In particular:

  1. How do I add the tar in the iso image.
  2. Where should I place the script.
  3. How to link the script so that it is executed at the end of the installation process.
share|improve this question
Can you revise the first sentence. Do you want to add the tar files to the iso image. – Tshepang Feb 4 '11 at 6:58
yes... i mean the same... i.e, adding some file to the .iso image of the installation cd... and then running some script post installation.... – pratap Feb 4 '11 at 8:24

While it's possible to rebuild a Red Hat CD ISO image, you might benefit from using the Kickstart mechanism available on existing Red Hat CDs/DVDs.

This is how I do something very similar to what you're asking. Simply create a kickstart and add a %post section that does whatever you're planning to do. You'll need to find a way to copy over the tar file, either by mounting an NFS share or using 'wget' to download from an HTTP server.

share|improve this answer
can u give a sample of the %post section, about how its done... i have been trying the same but not able to achieve it. – pratap Feb 11 '11 at 12:06
@pratap: I'm not sure I know what you want to do. Perhaps you want to simply download a script and run it? An example:wget -O somescript.sh http://mysite/somescript.sh; sh -x somescript.sh – jsbillings Feb 11 '11 at 13:17
can u tell me if i have todo the same from cd instead of network then how this is done? – pratap Feb 14 '11 at 3:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.