Public bug reported:
Concatenating multiple initrds works fine with gzipped initrds.
(microcode+gzip+gzip) => the kernel properly decompresses that
With lz4, it can't decompress anything after the first lz4:
(microcode+lz4+whatever) => it doesn't decompress whatever.
To reproduce:
Get vmlinuz and initrd.img from an eoan daily build and put them in a directory.
Create an lz4 (or gzip or uncompressed cpio, it doesn't matter):
# date > date.txt
# echo date.txt | cpio -oH newc | lz4 > date.img
Concatenate them:
# cat initrd.img.original date.img > initrd.img
Boot them:
# kvm -m 512 -kernel vmlinuz -initrd initrd.img -append rdinit=/bin/sh
Then inside kvm:
# ls /date.txt
The additional file doesn't exist.
`dmesg | grep -i initramfs` reports:
Trying to unpack rootfs image as initramfs...
Initramfs unpacking failed: Decoding failed
** Affects: linux (Ubuntu)
Importance: Undecided
Status: New
** Description changed:
Concatenating multiple initrds works fine with gzipped initrds.
(microcode+gzip+gzip) => the kernel properly decompresses that
With lz4, it can't decompress anything after the first lz4:
(microcode+lz4+whatever) => it doesn't decompress whatever.
To reproduce:
Get vmlinuz and initrd.img from an eoan daily build and put them in a
directory.
Create an lz4 (or gzip or uncompressed cpio, it doesn't matter):
+ # date > date.txt
# echo date.txt | cpio -oH newc | lz4 > date.img
Concatenate them:
# cat initrd.img.original date.img > initrd.img
Boot them:
# kvm -m 512 -kernel vmlinuz -initrd initrd.img -append rdinit=/bin/sh
Then inside kvm:
# ls /date.txt
The additional file doesn't exist.
** Description changed:
Concatenating multiple initrds works fine with gzipped initrds.
(microcode+gzip+gzip) => the kernel properly decompresses that
With lz4, it can't decompress anything after the first lz4:
(microcode+lz4+whatever) => it doesn't decompress whatever.
To reproduce:
Get vmlinuz and initrd.img from an eoan daily build and put them in a
directory.
Create an lz4 (or gzip or uncompressed cpio, it doesn't matter):
# date > date.txt
# echo date.txt | cpio -oH newc | lz4 > date.img
Concatenate them:
# cat initrd.img.original date.img > initrd.img
Boot them:
# kvm -m 512 -kernel vmlinuz -initrd initrd.img -append rdinit=/bin/sh
Then inside kvm:
# ls /date.txt
The additional file doesn't exist.
+
+ `dmesg` reports:
+ Trying to unpack rootfs image as initramfs...
+ Initramfs unpacking failed: write error
** Description changed:
Concatenating multiple initrds works fine with gzipped initrds.
(microcode+gzip+gzip) => the kernel properly decompresses that
With lz4, it can't decompress anything after the first lz4:
(microcode+lz4+whatever) => it doesn't decompress whatever.
To reproduce:
Get vmlinuz and initrd.img from an eoan daily build and put them in a
directory.
Create an lz4 (or gzip or uncompressed cpio, it doesn't matter):
# date > date.txt
# echo date.txt | cpio -oH newc | lz4 > date.img
Concatenate them:
# cat initrd.img.original date.img > initrd.img
Boot them:
# kvm -m 512 -kernel vmlinuz -initrd initrd.img -append rdinit=/bin/sh
Then inside kvm:
# ls /date.txt
The additional file doesn't exist.
- `dmesg` reports:
+ `dmesg | grep -i initramfs` reports:
Trying to unpack rootfs image as initramfs...
- Initramfs unpacking failed: write error
+ Initramfs unpacking failed: Decoding failed
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1840945
Title:
Concatenated lz4 initrds don't work
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1840945/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs