[CentOS-devel] how to update install CD ?

Fri Jan 18 11:10:55 UTC 2008
Johnny Hughes <johnny at centos.org>

dhongqian wrote:
> Hello,everyone:
>     I'm sorry that "/data/OWLinux"   is my written mistake.
> 
> Now It can find the cd, but the cd does not match my boot media.
> 
>      " No CentOS CD was found which matches your boot media. Please insert
>        the CentOS CD and press OK to  retry".
> 
> Why?
>           My discinfo is :
> 
> 1200551587.126943
> CentOS-4
> i386
> 1,2,3
> CentOS/base
> CentOS/RPMS
> CentOS/pixmaps
> 
> the original discinfo is :
> 
> CentOS-4 i386
> i386
> 1,2,3
> CentOS/base
> CentOS/RPMS
> CentOS/pixmaps
> 
> the discinfo is generate by the buildinstall.
> 
> My step is that:
> 
> genhdlist --productpath=CentOS /data/centos
> 
> pkgorder --product CentOS /data/centos/ CentOS > /data/pkgfile
> 
> buildinstall --pkgorder /data/pkgfile \
> --version "4" \
> --product "CentOS" \
> --release "CentOS-4" \
> --prodpath CentOS /data/centos
>       
> 
> 
> 2008-01-17 
> 
> 
> 
> dhongqian 
> 
> 
> 

When you use buildinstall, you are creating a new distro spin.  You
should get a new set of install images generated (in the /images
directory) and a new boot.iso.  You can not use the old boot.iso or
images directory (from the CentOS tree) anymore as the time stamps are
different.

The reason is that the initrd images (on all the CDs, the boot.iso CD,
the pxeinstall dir, the pen drive .img file, etc.) and the .discinfo
files on the CDs must all contain the same timestamp, and a new one is
generated when you run buildinstall.

1200551587.126943 is the timestamp on the one that you posted, the one
for centos-4.6 is 1195488871.805863 (that is the i386 version, each arch
has it's own timestamp when buildinstall was  run).  I am not sure all
the places this is checked for inside the install initrd image by anaconda.

I do not easily see a way to pass in a timestamp to buildinstall, here
is all the documentation I can find about it:

http://fedoraproject.org/wiki/Anaconda/BuildInstall

It is possible to edit the initrd.img file (and the boot.iso) to contain
a different timestamp, though I have personally never done this.  Google
knows how :D

Also, here is the script that is in use by CentOS to build CentOS-4 from
the tree (this one was when the CentOS version was 4.3, but it is the same:

http://mirror.centos.org/centos/4/build/distro/build.sh.txt

Regardless, this is not easy to do.  It is even harder if you want the
items you produce to also still use other CentOS install media that
already exist.  Unless you REALLY need to have your programs on the CD,
the best bet is to use the normal CentOS CDs and create a separate repo
and use yum to install your programs after the fact.

Thanks,
Johnny Hughes


> 发件人: Matt Hyclak 
> 发送时间: 2008-01-16  23:14:22 
> 收件人: The CentOS developers mailing list. 
> 抄送: 
> 主题: Re: [CentOS-devel] how to update install CD ? 
>  
> On Wed, Jan 16, 2008 at 02:54:30PM +0000, James Pearson enlightened us:
>>>       I want to add new rpm into install cd .
>>> I have searched the answer on the net and done it 
>>> like what they have said.
>>>       But when I use the cd I made to install OS, It told me that 
>>> " The CentOS-4 i386 CD was not found in any of your CDROM drivers.
>>> Please insert the CentOS-4 i386 cd and press OK to retry". I don't know
>>> why. Could anyone help ?
>>>
>>>  The following is the step :
>>> pkgorder --product CentOS  /data/CentOS/ CentOS > /data/pkgfile
>>> genhdlist --productpath=CentOS /data/OWLinux
>>> pkgorder --product CentOS  /data/CentOS/ CentOS > /data/pkgfile
>>>
>>> buildinstall --pkgorder /data/pkgfile \
>>> --version "4" \
>>> --product "CentOS" \
>>> --release "1" \
>>> --prodpath CentOS /data/OWLinux
>>>
>>> mkisofs -J -R -v -T -o ./CentOS.iso -V CentOS-4 -b \
>>>        isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot \
>>>        -boot-load-size 4  -boot-info-table ./CentOS/
>> In the above commands you are using /data/CentOS for the pkgorder and 
>> genhdlist, and /data/OWLinux with buildinstall - so you might not 
>> actually be making a CD of install you've just created ...
>>
>> Are there any errors from the buildinstall process?
>>
>> Also, I'm not sure why you are running pkgorder twice - I re-build the 
>> installer by running genhdlist, pkgorder and then genhdlist again with 
>> the output from pkgorder before running buildinstall
>>
> Most likely you are missing the .discinfo file.
> Matt


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
URL: <http://lists.centos.org/pipermail/centos-devel/attachments/20080118/2adf28ad/attachment-0007.sig>