[Fedora-livecd-list] Bug in livecd-iso-to-disk for netinst images [SOLVED]

Richard Shaw hobbes1069 at gmail.com
Thu Jun 17 04:13:03 UTC 2010


On Tue, Jun 15, 2010 at 4:22 PM, Richard Shaw <hobbes1069 at gmail.com> wrote:
> On Tue, Jun 15, 2010 at 3:19 PM, Jasper Hartline
> <jasper.hartline at gmail.com> wrote:
>> On Tue, Jun 15, 2010 at 10:35 AM, Richard Shaw <hobbes1069 at gmail.com> wrote:
>>> I have the following bug[1] filed initially against anaconda but I
>>> think it's really a bug in the livecd-iso-to-disk utility.
>>>
>>> To summarize here:
>>> I used the livecd-iso-to-disk utility to setup a usb flash drive with
>>> the Fedora 13 netinstall iso. The problem is that the tool sets up the
>>> repo= parameter to anaconda which prevents anaconda from using an
>>> online source for packages. From what I understand now it should
>>> specify the stage2= parameter instead, which will allow anaconda to
>>> use the local install.img but still get installation packages from
>>> another source.
>>
>> I'm sure any patches are welcome if you believe this is a problem in
>> livecd-iso-to-disk
>> We have several people available who can commit.
>
> I'm not a bash programmer but I do know some python, but here's what I
> think is wrong, in theory...
>
> The detection portion of the code:
> ---
> detectisotype() {
>    if [ -e $CDMNT/LiveOS/squashfs.img ]; then
>        isotype=live
>        return
>    fi
>    if [ -e $CDMNT/images/install.img ]; then
>        isotype=installer
>        return
>    fi
>    echo "ERROR: $ISO does not appear to be a Live image or DVD installer."
>    exitclean
> }
> ---
> There needs to be a third option with the correct logic to figure out
> that install.img is available, but packages are not. Maybe it could be
> something like isotype=net_installer.
>
> Then this part:
> ---
> # DVD Installer
> if [ "$isotype" = "installer" ]; then
>  sed -i -e "s;initrd=initrd.img;initrd=initrd.img
> repo=hd:$USBLABEL:/;g" $BOOTCONFIG $BOOTCONFIG_EFI
>  sed -i -e "s;stage2=\S*;;g" $BOOTCONFIG $BOOTCONFIG_EFI
> fi
> ---
> Might need to look like:
> ---
> # DVD Net Installer
> if [ "$isotype" = "net_installer" ]; then
>  sed -i -e "s;initrd=initrd.img;initrd=initrd.img
> stage2=hd:$USBLABEL:/;g" $BOOTCONFIG $BOOTCONFIG_EFI
>  sed -i -e "s;stage2=\S*;;g" $BOOTCONFIG $BOOTCONFIG_EFI
> fi
> ---
> Although I think the 2nd sed line would need to occur first or I think
> it will erase what the first sed line does.

I finally have F13 installing from the netinst image on my EEEPC!

I don't think anything I wrote previously is incorrect but I have some
things to add:
- There's no point in copying over the ISO of the netinst image to the
USB disk because it doesn't contain the installer packages.
- Updating the repo= to stage2= is correct but you also have to add
the full path to install.img, i.e:
stage2=hd:UUID=<UUID>:/images/install.img

Bug report[1] with patch has been submitted.

Richard

[1] http://bugzilla.redhat.com/show_bug.cgi?id=604942


More information about the livecd mailing list