lkml.org 
[lkml]   [2009]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Initramfs from existing vmlinuz
    On Mon, Jan 05, 2009 at 11:12:26AM +0000, Ian Campbell wrote:
    > On Wed, 2008-12-24 at 00:34 +0100, Willy Tarreau wrote:
    > > You first have to extract and uncompress the ELF image from vmlinuz.
    > > For this, look for the gzip signature 1F 8B 08 in your vmlinuz, and
    > > feed all data starting from this point to zcat.
    >
    > Since v2.6.26 (I think, it was v2.08 of the x86 bzImage format anyhow,
    > which was the same point the payload became ELF formatted) you can find
    > it directly using the payload_offset and payload_length fields in the
    > bzImage header. Attached bzexplode.c demonstrates this. e.g. "bzexplode
    > vmlinuz | zcat > vmlinux.elf"

    Thanks Ian.

    Indeed, I'm sure this will be useful from time to time!

    Cheers,
    Willy



    \
     
     \ /
      Last update: 2009-01-05 12:51    [W:0.018 / U:91.180 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site