• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

mkinitrd: command not found

by admin

The mkinitrd command is used to create the initrd image for preloading the kernel modules. Various options of the mkinitrd command are given in the following table.

Option Description
—preload={module name} Load a module in the initrd image before the loading of other modules.
–with={module name} Load a module in the initrd image after the loading of other modules.
-f Overwrite an existing initrd image file.
—nocompress Disable the compression of the initrd image.

Syntax

The syntax of the mkinitrd command is:

# mkinitrd [options] {initrd image name} {kernel version}

The following example creates an initrd image from the current kernel version and names the image initrd-[kernel version].img:

# mkinitrd /boot/initrd-$(uname -r).img $(uname -r)

If you encounter the below error while running the mkinitrd command:

mkinitrd: command not found

you may try installing the below package as per your choice of distribution:

OS Distribution Command
Debian apt-get install dracut
Ubuntu apt-get install dracut
Kali Linux apt-get install dracut
CentOS yum install dracut
Fedora dnf install dracut
Raspbian apt-get install dracut

Filed Under: Linux

Some more articles you might also be interested in …

  1. boltctl Command Examples in Linux
  2. Active FTP vs. Passive FTP
  3. How To Use distro-sync Option With dnf To Upgrade OS (CentOS/RHEL 8)
  4. ldd Command Options in Linux
  5. hdparm Command Examples in Linux
  6. Monitor HDD and SSD with smartd and smartctl
  7. lrzuntar: command not found
  8. cut: command not found
  9. mandb Command Examples in Linux
  10. RHEL 7 – RHCSA Notes – vi/vim editor

You May Also Like

Primary Sidebar

Recent Posts

  • nixos-rebuild Command Examples in Linux
  • nixos-option: Command Examples in Linux
  • nixos-container : Command Examples in Linux
  • nitrogen Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright