Activity log for bug #1961118

Date Who What changed Old value New value Message
2022-02-16 22:40:00 Robert Reitz bug added bug
2022-02-16 22:40:00 Robert Reitz attachment added mountfix workaround https://bugs.launchpad.net/bugs/1961118/+attachment/5561484/+files/mountfix.patch
2022-02-16 22:41:58 Robert Reitz description In the context of a automatic preseed / subiquity installation usage of the efitools fails inside the target chroot provided by the curtin tool. curtin does setup the sys and efivarfs filesystems correctly: curtin in-target --target=/target -- efi-readvar No efivarfs filesystem is mounted efitools is using the mount util while searching for the efivarfs. It's parsing the output of "mount -l". This error is not triggered by the successfully mounted efivarfs but by parsing the mount list while searching for the efivarfs. The subiquity system provides one relative unusual mount entry which let the parser of efitools stop working even if the efivarfs is mounted: curtin in-target --target=/target -- mount -l ... /ubuntu-21.10-live-server-amd64.iso (deleted) on /cdrom type iso9660 (ro,relatime,nojoliet,check=s,map=n,blocksize=2048) [Ubuntu-Server 21.10 amd64] ... efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime) ... On the Ubuntu ISO line the keyword "(deleted)" is unsupported by the parser of efitools in efitools/lib/kernel_efivars.c I'm not really sure if this is maybe a bug of the mount util, but anyway it is probably better to skip lines which can not be parsed successfully instead of stopping work completely. Attached is a simple and maybe suboptimal patch to skip lines which doesn't return the expected number of found arguments, which in turn skips all unexpected lines, so that finally the efivarfs can be found the the tools like efi-readvar and efi-updatevar are working. In the context of an automatic preseed / subiquity installation usage of the efitools fails inside the target chroot provided by the curtin tool. curtin does setup the sys and efivarfs filesystems correctly: curtin in-target --target=/target -- efi-readvar No efivarfs filesystem is mounted efitools is using the mount util while searching for the efivarfs. It's parsing the output of "mount -l". This error is not triggered by the successfully mounted efivarfs but by parsing the mount list while searching for the efivarfs. The subiquity system provides one relative unusual mount entry which let the parser of efitools stop working even if the efivarfs is mounted: curtin in-target --target=/target -- mount -l ... /ubuntu-21.10-live-server-amd64.iso (deleted) on /cdrom type iso9660 (ro,relatime,nojoliet,check=s,map=n,blocksize=2048) [Ubuntu-Server 21.10 amd64] ... efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime) ... On the Ubuntu ISO line the keyword "(deleted)" is unsupported by the parser of efitools in efitools/lib/kernel_efivars.c I'm not really sure if this is maybe a bug of the mount util, but anyway it is probably better to skip lines which can not be parsed successfully instead of stopping work completely. Attached is a simple and maybe suboptimal patch to skip lines which doesn't return the expected number of found arguments, which in turn skips all unexpected lines, so that finally the efivarfs can be found and the tools like efi-readvar and efi-updatevar are working.
2022-02-16 22:48:23 Robert Reitz description In the context of an automatic preseed / subiquity installation usage of the efitools fails inside the target chroot provided by the curtin tool. curtin does setup the sys and efivarfs filesystems correctly: curtin in-target --target=/target -- efi-readvar No efivarfs filesystem is mounted efitools is using the mount util while searching for the efivarfs. It's parsing the output of "mount -l". This error is not triggered by the successfully mounted efivarfs but by parsing the mount list while searching for the efivarfs. The subiquity system provides one relative unusual mount entry which let the parser of efitools stop working even if the efivarfs is mounted: curtin in-target --target=/target -- mount -l ... /ubuntu-21.10-live-server-amd64.iso (deleted) on /cdrom type iso9660 (ro,relatime,nojoliet,check=s,map=n,blocksize=2048) [Ubuntu-Server 21.10 amd64] ... efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime) ... On the Ubuntu ISO line the keyword "(deleted)" is unsupported by the parser of efitools in efitools/lib/kernel_efivars.c I'm not really sure if this is maybe a bug of the mount util, but anyway it is probably better to skip lines which can not be parsed successfully instead of stopping work completely. Attached is a simple and maybe suboptimal patch to skip lines which doesn't return the expected number of found arguments, which in turn skips all unexpected lines, so that finally the efivarfs can be found and the tools like efi-readvar and efi-updatevar are working. In the context of an automatic preseed / subiquity installation usage of the efitools fail inside the target chroot provided by the curtin tool. curtin does setup the sys and efivarfs filesystems correctly: curtin in-target --target=/target -- efi-readvar No efivarfs filesystem is mounted efitools is using the mount util while searching for the efivarfs. It's parsing the output of "mount -l". This error is not triggered by the successfully mounted efivarfs but by parsing the mount list while searching for the efivarfs. The subiquity system provides one relative unusual mount entry which let the parser of efitools stop working even if the efivarfs is mounted: curtin in-target --target=/target -- mount -l ... /ubuntu-21.10-live-server-amd64.iso (deleted) on /cdrom type iso9660 (ro,relatime,nojoliet,check=s,map=n,blocksize=2048) [Ubuntu-Server 21.10 amd64] ... efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime) ... On the Ubuntu ISO line the keyword "(deleted)" is unsupported by the parser of efitools in efitools/lib/kernel_efivars.c I'm not really sure if this is maybe a bug of the mount util, but anyway it is probably better to skip lines which can not be parsed successfully instead of stopping work completely. Attached is a simple and maybe suboptimal patch to skip lines which doesn't return the expected number of found arguments, which in turn skips all unexpected lines, so that finally the efivarfs can be found and the tools like efi-readvar and efi-updatevar are working.
2022-02-17 00:28:20 Ubuntu Foundations Team Bug Bot tags patch
2022-02-17 00:28:28 Ubuntu Foundations Team Bug Bot bug added subscriber Ubuntu Review Team
2022-03-11 09:52:00 Martin Schmitt bug added subscriber Martin Schmitt