lsinitramfs
List contents of an initramfs image
SYNOPSIS
lsinitramfs [options] [initramfs-image...]
PARAMETERS
-h, --help
Display help text and exit.
-v, --verbose
Enable verbose output. Shows extraction progress.
-l, --long
Display in long listing format.
-m, --metadata
Display metadata information of the initramfs image.
-f, --file [filename]
Instead of extracting the initramfs to a temporary directory, extract it to the directory pointed by filename.
initramfs-image...
One or more initramfs image files to list. If not specified, the current initramfs image used for the running kernel is used.
DESCRIPTION
The `lsinitramfs` command allows you to inspect the contents of initramfs (initial RAM file system) images. Initramfs images are used during the early boot process of a Linux system to load necessary kernel modules and user-space utilities before the root file system is mounted. Using `lsinitramfs`, you can list the files and directories contained within an initramfs image, effectively peeking inside to understand its structure and contents.
This is particularly useful for debugging boot issues, understanding the modules included, verifying configuration files, or customizing the initramfs environment. You can specify multiple initramfs images, and the command will list the contents of each specified image. The command relies on standard utilities like `cpio` to unpack the initramfs archive. It's a valuable tool for system administrators, kernel developers, and anyone who needs to work with the Linux boot process.
DEFAULT BEHAVIOR
If no initramfs image is specified, `lsinitramfs` attempts to determine the currently running kernel's initramfs image and lists its contents. This allows quick inspection of the currently used boot image.
EXAMPLES
lsinitramfs /boot/initrd.img-$(uname -r)
will list the content of the current Kernel Init Ram File System
lsinitramfs -l /boot/initrd.img-$(uname -r)
will list the content with detailed information.
SEE ALSO
mkinitramfs(8), update-initramfs(8), dracut(8)