Unable to deploy Fedora 30

Bug #1841500 reported by Lee Trager
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
curtin
Triaged
Wishlist
Unassigned

Bug Description

As a proof of concept I tried to create a Fedora image for MAAS. Curtin fails to install using its internal hooks for two reasons.

1. Fedora no longer installs the kernel package. It is now called kernel-core, kernel is only available as a meta-package.
2. install-grub no longer exists in Fedora. grub2-install must be used instead.

How to create the image

1. Download the image from https://alt.fedoraproject.org/cloud/
2. Load the nbd kernel modules
    sudo modprobe nbd
3. Load the image
    sudo qemu-nbd -c /dev/nbd1 debian-10.0.3-20190815-openstack-amd64.qcow2
4. Mount the root partition
    sudo mount /dev/nbd1p1 /mnt/
5. Mount /sys and /proc so you can chroot in
    sudo mount -o bind /sys /mnt/sys
    sudo mount -o bind /proc /mnt/proc
6. Copy /etc/resolv.conf into the image so DNS works in the chroot
    sudo mv /mnt/etc/resolv.conf /mnt/etc/resolv.conf.bak
    sudo cp /etc/resolv.conf /mnt/etc
7. Chroot in and install additional packages needed by MAAS
    chroot /mnt
    dnf install python-oauthlib bridge-utils grub2-efi-x64-modules efibootmgr lvm2 mdadm
    # Needed to work around part of this bug
    dnf install kernel
    exit
8. Unmount /proc, /sys
    umount /mnt/sys
    umount /mnt/proc
9. Restore /etc/resolv.con
    mv /mnt/etc/resolv.conf.bak /mnt/etc/resolv.conf
10. Create tgz
    tar -czpf Fedora-Cloud-Base-30-1.2.x86_64.tgz -C /mnt .
11. Upload it to MAAS
    maas $PROFILE boot-resources create name=’fedora-30’ architecture=’amd64/generic’ content@=Fedora-Cloud-Base-30-1.2.x86_64.tgz

Revision history for this message
Ryan Harper (raharper) wrote :

MAAS can provide kernel config with the correct package names:

kernel:
   fallback-package: 'kernel-core'

Curtin doesn't invoke grub commands directly, rather it calls it's own helper, install_grub.
The distro family is passed in (redhat) in which case curtin does grub2-install + grub2-mkconfig.

I suspect that will work just fine for fedora.

The change that current needs is to add a dnf wrapper around the yum command support it has.

Changed in curtin:
importance: Undecided → Wishlist
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.