LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 09-12-2006, 07:08 AM   #1
mahabooba
Member
 
Registered: Dec 2005
Posts: 43

Rep: Reputation: 15
Creation of ISO(FC5 based)?


Hi All,
We are planing to develop our own distribution based on Fedora Core 5. But We are facing problem with the ISO image procedure.
Please let me know the detail process to create the FC5 based ISO image.

Thanks in Advance.

Regards,
MahaboobAli.Shaik
 
Old 09-12-2006, 10:22 AM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
man mkisofs
 
Old 09-13-2006, 05:35 AM   #3
mahabooba
Member
 
Registered: Dec 2005
Posts: 43

Original Poster
Rep: Reputation: 15
Thank you .But In FC5 I am unable to find "comps.xml" in /usr/share/comps/i386/

For FC3 and Fc4 ISO IMAGE creatiom I am doing in this way...

Create a directory for your work environment. ( /home/hs/i386)

Create the directory structure under this area like
mkdir /home/hs/i386/Host
mkdir /home/hs/i386/Host/base
mkdir /home/hs/i386/Host/RPMS
mkdir /home/hs/i386/Host/SRPMS

Copy all the Binary RPMS into the directory /home/hs/i386/Host/RPMS/
Copy the SRPMS into the directory /home/hs/i386/Host/SRPMS/

Run the genhdlist command to check image
/usr/lib/anaconda-runtime/genhdlist --withnumbers --productpath= \ Host /home/hs/i386/
If the command is successful then there will be files such as hdlist, hdlist2 in the directory /home/hs/i386/Host/base. This command may report about the duplicate packages if found.

Edit the comps.xml file, this is the crucial part in making the ISO.
After editing the comps.xml, once again run the genhdlist and then check it with getfullcomps.py
/usr/share/comps-extras/getfullcomps.py comps.xml \ /home/hs i386 > /dev/null
Before proceed to next step, check for there are no dependency problems.

Run the pkgorder command to generate the package order. But before that don't forget to set the PYTHONPATH
export PYTHONPATH=/usr/lib/anaconda
/usr/lib/anaconda-runtime/pkgorder /home/hs/i386 i386 Host|\ tee /home/hs/pkgorder.txt
This will generate the pkgorder file at the same time will display all the packages that you have added.
Build the anaconda installer images
/usr/lib/anaconda-runtime/buildinstall --comp dist-9 \
--pkgorder /home/hs/pkgorder.txt --product 'Host Linux' \
--release 1 --version 1 --prodpath Host /home/hs/i386
This command will generate the installer images for your distribution.

Split the packages inorder to write those in CD's
/usr/lib/anaconda-runtime/splittree.py --arch=i386 --total- discs=5 --bin-discs=3 --src-discs=2 --release-string="Host Linux" --pkgorderfile=/home/hs/pkgorder --distdir=i386
--srcdir=SRPMS --productpath=Host

If there are no SRPMS in your buildtree then a warning will raised indicating the failure of packaging SRPMS , which can be ignored if you are not bothered about creating source CDs. If you want to reduce the number of CDs, then use the following command
/usr/lib/anaconda-runtime/splittree.py --arch=i386 --total- discs=3 --bin-discs=2 --src-discs=1 --release-string="Host Linux"
--pkgorder=/home/hs/pkgorder.txt --distdir=i386 --srcdir=SRPMS
--productpath=Host

Once again runt the genhdlist, to create new hdlist files, but this time referencing the "package order catalogue" and the newly-created i386-disc[123] directory trees...
rm -f /home/hs/i386-disc1/Host/base/hdlist*
/usr/lib/anaconda-runtime/genhdlist --withnumbers
--fileorder /home/hs/pkgorder.txt
/home/hs/i386-disc[123] --productpath Host

Make the ISO images for all the CD's

mkisofs -b images/diskboot.img -c isolinux/boot.cat -v -r -T -J -V Host-1.0_D1 -o /home/hs/HL_D1.iso /home/hs/i386-disc1
mkisofs -JR -l -V Host-1.0_D2 -o HL_D2.iso i386-disc2
If the diskboot image is not a Floppy sized one, you will be getting an error as Size of the Diskboot is large. In this situation you can create the ISO image considering that the diskboot image as an hard disk image, for this you have to add some more options to the command.
mkisofs -o /home/hs/HL_D1.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size=4 -boot-info-table -R -J -v -T /home/hs/i386-disc1
For the other Other discs
mkisofs -o /home/hs/HL_D2.iso -R -J -v -T /home/hs/i386-disc2

Finally, Burn the image to the CD using cdrecord, xcdroast or gtoaster and it's ready for Installation.


But How to prepare the ISO image in FC5.
Please help me in this regard.

Thanks and Regards,
Mahaboob Ali.Shaik
 
Old 09-13-2006, 11:21 AM   #4
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
This is a problem much bigger than creating an ISO image. You are trying to reverse engineer the entire packaging system developed by Redhat/Fedora. Perhaps they have documented that system somewhere. Good luck.

--- rod.
 
Old 09-22-2006, 06:47 AM   #5
mahabooba
Member
 
Registered: Dec 2005
Posts: 43

Original Poster
Rep: Reputation: 15
Hi all, using the following script we can build the ISO image based on FC5.
Thanks and Regards,
Mahaboob Ali.Shaik
#!/bin/sh

# Create tailored Fedora Core 5 binary DVD and/or CD images.

# Hold on to your hats, because this ain't for those with heart
# or back conditions or those who think they might be pregnant.

# Orginal ideas and script by Rob Garth and Simone Caronni. Thx!
# http://www.users.on.net/~rgarth/webl.../patch_cd.html

# This script needs about 20-25 GByte disc space and a lot of time.

# Make sure to have the following packages installed:
# createrepo, yum-utils, anaconda, and anaconda-runtime.

# Create a new directory, e.g. "/csfedora/",
# and copy (!) complete FC DVD contents to "/csfedora/i386/".
# Alternatively, copy the complete FC CD1 to "/csfedora/i386/"
# and then "Fedora/RPMS/*rpm" of all other CDs to
# "/csfedora/i386/Fedora/RPMS/".

# Mount (or download) the updates to "/csfedora/updates/".
# This dir can be empty.

# So, this script could also be used to create a DVD from CD images
# or vice versa (copy as above and leave "/csfedora/updates/" empty).
# One can also create a DVD from DVD or CDs from CDs, but where's the point?

# Run this script as root in the "/csfedora/" directory.

# Structure: /csfedora/i386/ - contents of original DVD,
# /csfedora/updates/ - directory with the updates,
# /csfedora/update_fedora.sh - this script.

# Note: The "/csfedora/i386/" directory will be updated,
# the "/csfedora/updates/" will not be touched.

# The script outputs a DVD and/or 5 CD image(s) to the /csfedora/ dir.

# BUILD_DVD=1 -> create DVD ISO image, BUILD_DVD=0 -> don't create DVD ISO
BUILD_DVD=1
# BUILD_CDS=1 -> create 5 CD ISO images, BUILD_CDS=0 -> don't create CD ISOs
BUILD_CDS=1

export PYTHONPATH=/usr/lib/anaconda
export PATH="$PATH:/usr/lib/anaconda-runtime"
export FCBASE=`pwd`
arch=`uname -i`
date=`date +%Y%m%d`

publisher="kh, mailtoenguin73 at gmx dot de"
release="5"

echo "`date` - Merging updates ..."
cp -f $FCBASE/updates/*.rpm $FCBASE/$arch/Fedora/RPMS/
repomanage --old $FCBASE/$arch/Fedora/RPMS | xargs rm -f

# if you want to tailor the installation, here are a few pointers:
# * Replace anaconda with a custom package for replaced artwork.
# * Add your own packages:
# Copy additional RPMs to $FCBASE/$arch/Fedora/RPMS
# To install these packages, refer to them in a kickstart file.
# * Automate the installation with kickstart files:
# copy kickstart files to $FCBASE/$arch/
# http://www.redhat.com/docs/manuals/e...ickstart2.html
echo "`date` - Adding non-Fedora stuff ..."
# copy kickstart files to $FCBASE/$arch/
#cp -a /my_ks/*cfg $FCBASE/$arch/
# copy additional RPMS to (or replace existing RPMs in) $FCBASE/$arch/Fedora/RPMS
#cp -a /my_rpms/*rpm $FCBASE/$arch/Fedora/RPMS/

echo "`date` - Creating repo ..."
cd $FCBASE/$arch
# First createrepo is for the tree
createrepo -g Fedora/base/comps.xml .
rm -rf .olddata/
cd ..

echo "`date` - Rebuilding installer ..."
pkgorder --product=Fedora $FCBASE/$arch \
$arch Fedora > $FCBASE/pkgfile.$date
buildinstall --comp dist-$release.$date \
--pkgorder $FCBASE/pkgfile.$date --version $release \
--product 'Fedora Core' --release "Fedora Core $release" \
--prodpath Fedora $FCBASE/$arch

if [ $BUILD_DVD -eq 1 ]; then
echo "`date` - Creating DVD ISO ..."

# we need to run createrepo a second time (for the media)
dvd_discinfo=`head -1 $FCBASE/$arch/.discinfo`
createrepo --baseurl="media://$dvd_discinfo" -g Fedora/base/comps.xml \
--split $arch
rm -rf .olddata/

find $arch -name "TRANS.TBL" -exec rm -f {} \;
mkisofs -q -r -R -J -T -no-emul-boot -boot-load-size 4 \
-b isolinux/isolinux.bin -c isolinux/boot.cat -boot-info-table \
-V "FC $release update$date $arch DVD" \
-A "Fedora Core $release update$date $arch DVD" \
-publisher "$publisher" -p "$publisher" -x lost+found \
-o FC-$release-update$date-$arch-DVD.iso $arch
implantisomd5 FC-$release-update$date-$arch-DVD.iso
fi

if [ $BUILD_CDS -eq 1 ]; then
echo "`date` - Creating CD images ..."
splittree.py --arch=i386 \
--total-discs=5 --bin-discs=5 --src-discs=0 --srcdir=. \
--release-string="Fedora Core $release" \
--pkgorderfile=$FCBASE/pkgfile.$date --distdir=$FCBASE/$arch \
--productpath=Fedora

# we need to run createrepo a second time (for the media)
cd_discinfo=`head -1 $FCBASE/$arch-disc1/.discinfo`
createrepo --baseurl="media://$cd_discinfo" -g Fedora/base/comps.xml \
--split $arch-disc?
rm -rf .olddata/

echo -n "writing image for CD1"
# The first CD is special (because it needs to be bootable)
mkisofs -q -r -R -J -T -no-emul-boot -boot-load-size 4 -boot-info-table \
-b isolinux/isolinux.bin -c isolinux/boot.cat \
-V "FC $release update$date $arch" \
-A "Fedora Core $release update$date $arch" \
-publisher "$publisher" -p "$publisher" -x lost+found \
-o FC-$release-update$date-$arch-disc1.iso $FCBASE/$arch-disc1

CDS="2 3 4 5"
for num in $CDS
do
echo -n " ... CD$num"
mkisofs -q -r -R -J -T \
-V "FC $release update$date $arch" \
-A "Fedora Core $release update$date $arch" \
-publisher "$publisher" -p "$publisher" -x lost+found \
-o FC-$release-update$date-$arch-disc$num.iso $FCBASE/$arch-disc$num
done

echo ""

CDS="1 2 3 4 5"
for num in $CDS
do
implantisomd5 FC-$release-update$date-$arch-disc$num.iso
done
fi

echo "`date` - Cleanup ..."
rm -rf $arch-disc?/
rm -f $FCBASE/pkgfile.$date

echo "`date` - Finished."


----------------------------------------------------------------------------------
 
Old 10-03-2006, 10:48 PM   #6
mahabooba
Member
 
Registered: Dec 2005
Posts: 43

Original Poster
Rep: Reputation: 15
Hi all,
Using above script ISO image creation is done . And installation also completed but at first boot onwards It shows the following error. ata2: Disabaling port Kernel panic! Unable to synchronize..... After that System is hangedout. Please help me in this regard. Thanks in advance.
 
Old 10-08-2007, 10:52 AM   #7
tkmsr
Member
 
Registered: Oct 2006
Distribution: Ubuntu,Open Suse,Debian,Mac OS X
Posts: 798

Rep: Reputation: 39
Quote:
Originally Posted by mahabooba View Post
Hi all,
Using above script ISO image creation is done . And installation also completed but at first boot onwards It shows the following error. ata2: Disabaling port Kernel panic! Unable to synchronize..... After that System is hangedout. Please help me in this regard. Thanks in advance.
Thanks a lot for such a post I was searching for many days I have googled and found some problem might be it is related to your work or you may give a solution to me read it here
http://www.linuxquestions.org/questi...e-10.2-589293/
I think apart from building the packages the initrd amd vmlinuz that the DVD or CD holds also need to be created from scratch
http://www.linuxfromscratch.org/hint.../initramfs.txt

then see this
http://www.linuxquestions.org/questi...-image-590289/
people who are telling to reverse engineer if they can tell where all this process is documented would be helpful I have been searching and reading from many days but have not yet got anything
http://vertito.blogspot.com/2007/08/...tro-howto.html
You might need a tool like revisor ,Kiwi Cobbler or some thing else
http://fedora-respin.wikispaces.com/

in case you are able to make please let me know
http://www.users.on.net/~rgarth/webl.../patch_cd.html

One more link that was interesting
http://lxr.linux.no/source/Documenta...nitrd.txt#L256

Last edited by tkmsr; 10-08-2007 at 01:51 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Regarding Creation of Bootable ISO of hard disk image having multiple partitions.. nagamohan_p Linux - Newbie 1 08-26-2006 10:52 PM
Regarding Creation of Bootable ISO of hard disk image having multiple partitions.. nagamohan_p Programming 1 08-25-2006 09:11 AM
can't burn iso 3 and iso 4 for FC5 mnauta Fedora 1 04-02-2006 02:45 PM
FC5 development release and FC5 official release- where is the DVD iso? smiley_lauf Fedora 11 03-13-2006 01:38 PM
Web-Based Linux Account Creation br00tal Programming 2 02-21-2006 05:42 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 11:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration