The vmlinuz isn't just the compressed kernel, it's complete bootable image including the decompressor. To get just the image search for the GZ signature - 1f 8b 08 00. Now i'm sure there are scripts for it somewhere, but you can do it old-fashioned way - in my case:
# od -A d -t x1 vmlinuz-3.0.0-32-virtual | grep '1f 8b 08 00'
0015968 48 8d 83 00 b7 47 00 ff e0 1f 8b 08 00 00 00 00
so the image begins at 15968+9 => 15977 . Then just copy the image from the point and decompress it -
#dd if=vmlinuz bs=1 skip=15977 | zcat > vmlinux
记录了4718407+0 的读入
记录了4718407+0 的写出
# od -A d -t x1 vmlinuz-3.0.0-32-virtual | grep '1f 8b 08 00'
0015968 48 8d 83 00 b7 47 00 ff e0 1f 8b 08 00 00 00 00
so the image begins at 15968+9 => 15977 . Then just copy the image from the point and decompress it -
#dd if=vmlinuz bs=1 skip=15977 | zcat > vmlinux
记录了4718407+0 的读入
记录了4718407+0 的写出
4718407字节(4.7 MB)已复制,6.02327 秒,783 kB/秒
#