[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Using memdisk with grub2 and a gzip-compressed ISO
From: |
David Shaw |
Subject: |
Using memdisk with grub2 and a gzip-compressed ISO |
Date: |
Thu, 23 Apr 2015 10:23:09 -0400 |
Hello,
Pardon the cross-post to two lists, but this problem seems to lie in a somewhat
gray area between grub2 and memdisk. Basically, the problem is this: it used
to be possible to boot a compressed ISO image via memdisk and grub legacy, but
this no longer works with grub2.
Here's the setup: Two machines, both with 4GiB of RAM. The only difference
between the two is that one is using grub legacy (0.97) and the other is using
grub2 (2.02). I am using memdisk from syslinux 4.02 (though for completeness I
also tried 4.05 and 6.03, with the same results). The ISO image itself is
3388047 bytes gzip compressed and 9394176 bytes uncompressed.
The grub legacy configuration:
title boot ISO image
kernel /memdisk iso
initrd /my-image.iso.gz
The grub2 configuration:
menuentry 'boot ISO image' {
linux16 /memdisk iso
initrd16 /my-image.iso.gz
}
If anyone would like to see it, the sample gzip-compressed ISO image is at
http://www.jabberwocky.com/my-image.iso.gz
Now to the problem: When booting the box with grub 0.97, it works. The ISO
boots and the right things happen. Here's the output from memdisk:
Ramdisk at 0x37cb4000, length 0x0033b28f
gzip image: decompressed addr 0xbf5fa800, len 0x008f5800: ok
When booting the box with grub2 2.02, it does not work. The error is:
Ramdisk at 0x37979000, length 0x0033b290
gzip image: decompressed addr 0xbfff7000, len 0x00008f58: failed
Decompression error: output buffer overrun
I'm not sure if this is related to the problem, but note the length in the
"Ramdisk" line from grub legacy is one byte shorter than the length from grub2.
Also note that the length given in the "gzip image" line is shifted one byte
to the left in the grub legacy version (i.e. it's exactly 0x100 times larger).
1) I have tried this with memdisk from syslinux 4.02, 4.05, and 6.03 with the
same results each time.
2) Changing the level of compression (i.e. gzip -1 instead of gzip -9) does not
make a difference.
3) This works fine with an uncompressed image with grub2. This also works fine
with a zip-compressed image with grub2. It only seems to fail with a
gzip-compressed image with grub2.
Andrei Borzenkov kindly analyzed the image and suggested I contact both the
syslinux and grub groups as he has a notion of what went wrong. Andrei, can
you fill in anything I missed?
Thanks,
David
- Using memdisk with grub2 and a gzip-compressed ISO,
David Shaw <=
- Re: Using memdisk with grub2 and a gzip-compressed ISO, Andrei Borzenkov, 2015/04/23
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, H. Peter Anvin, 2015/04/23
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, Andrei Borzenkov, 2015/04/23
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, H. Peter Anvin, 2015/04/23
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, Andrei Borzenkov, 2015/04/23
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, H. Peter Anvin, 2015/04/24
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, Andrei Borzenkov, 2015/04/24
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, H. Peter Anvin, 2015/04/27
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, Vladimir 'φ-coder/phcoder' Serbinenko, 2015/04/29
- Re: [syslinux] Using memdisk with grub2 and a gzip-compressed ISO, Andrei Borzenkov, 2015/04/29