vmlinuz is the compressed, bootable image of the Linux kernel — the file that GRUB loads into memory at boot. A small stub inside it decompresses the rest of the kernel into RAM and hands off control to start the OS.

Fun Fact #1: What does the name vmlinuz mean?

The name vmlinuz is not accidental. It’s an acronym that can be broken down into parts, each with historical significance:

  • vm: Stands for “Virtual Memory”. In the early days of Linux, kernels that supported virtual memory (which is standard today) had this prefix to distinguish them from older versions that did not.
  • linu: This is simply short for “Linux”.
  • z: This indicates that the kernel image is compressed, most often using the gzip algorithm. It is this compression that makes the file much smaller than its raw counterpart, vmlinux. Modern kernels can also use other compression algorithms, such as lzma, xz, lzo, lz4, or zstd.

Fun Fact #2: vmlinux vs vmlinuz

You might also often come across a file named vmlinux (without the “z” at the end). What’s the difference?

  • vmlinux: This is the raw, uncompressed, non-bootable kernel image. It contains all the debugging symbols and is in ELF format. It is huge compared to vmlinuz and is mainly used for debugging and analyzing the kernel with tools like gdb or crash.
  • vmlinuz: This is the compressed and “stripped” version of vmlinux, prepared specifically for booting the system.

The process of creating vmlinuz from vmlinux involves removing unnecessary information, compressing it, and adding a small startup code responsible for decompression.

Fun Fact #3: What about bzImage?

When compiling the kernel, the command make bzImage is often used. Many people think that bz stands for bzip2 compression. Nothing could be further from the truth!

Historically, the first compressed kernel image was called zImage (from “compressed Image” – “z” as in gzip compression). However, it had a limitation – the entire compressed kernel had to fit into the first 640 KB of memory. As the kernel grew, this became a problem.

So, the bzImage format was introduced, where bz stands for “big zImage”, not bzip2. bzImage also uses gzip compression (or newer ones like lzo, xz, lz4, zstd), but thanks to a different memory organization, it allows for loading much larger kernel images.

Fun Fact #4: vmlinuz vs bzImage — Are They the Same?

Short answer: yes, practically the same. The difference is only in naming:

  • bzImage — this is the format and build target (make bzImage). The resulting file is located in arch/x86/boot/bzImage.
  • vmlinuz — this is the filename in the /boot directory, where the installer copies the compiled bzImage.

When you run make install after compiling the kernel, the installation script copies arch/x86/boot/bzImage to /boot/vmlinuz-<version>. It’s literally the same file, just under a different name.

Why Two Names?

  • bzImage describes how the file was built (the “big zImage” format for x86).
  • vmlinuz describes what it is (a compressed kernel with virtual memory support).

The name vmlinuz is more universal — it’s used regardless of architecture. On ARM or RISC-V there’s no “bzImage”, but /boot/vmlinuz still exists.

You Can Verify This

# After kernel compilation, compare the files:
cmp arch/x86/boot/bzImage /boot/vmlinuz-$(uname -r)
# If nothing is printed — the files are identical

# Check the compression type of vmlinuz:
file /boot/vmlinuz-$(uname -r)
# Example output: Linux kernel x86 boot executable bzImage, version 6.5.0...

Quick reference:

  • vmlinux — raw, uncompressed kernel image (for debugging)
  • zImage — old compressed format, ~512 KB limit
  • bzImage — modern “big zImage” format (make bzImage target)
  • vmlinuz — filename in /boot — usually a copy of bzImage