Comment 0 for bug 2038957

Revision history for this message
John Chittum (jchittum) wrote : ppcel64 images unpack to /boot/vmlinux not /boot/vmlinux leading to kernel feature mismatch

In a build of a ppcel64 image, snap_validate_seed fails to find the installed kernel to pick a matching apparmor feature set to mount. from the log

```
+ [ -e chroot/boot/vmlinuz ]
+ [ -e chroot/var/lib/snapd/seed/seed.yaml ]
+ snap debug validate-seed chroot/var/lib/snapd/seed/seed.yaml
+ realpath chroot
+ /usr/lib/snapd/snap-preseed --reset /build/chroot
ubuntu classic preseeding
unmounting: /build/chroot/tmp/snapd-preseed
ubuntu classic preseeding
unmounting: /tmp/snapd-preseed
+ realpath chroot
+ /usr/lib/snapd/snap-preseed /build/chroot
ubuntu classic preseeding
```

This corresponds to line 772 in livecd-rootfs/live-build/functions

snap_validate_seed() {
    local CHROOT_ROOT=$1
    local kern_major_min=undefined

    if [ -e ${CHROOT_ROOT}/boot/vmlinuz ]; then

ppcel64 however unpacks to /boot/vmlinux. For history:

https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1358920

for ppcel64 images, this function needs to be updated to check for `/boot/vmlinux`.

This will require an SRU 23.10 (post-release) and 22.04