mkosi-initrd(1)
π mkosi-initrd(1) β the general commands manual, but make it cute
okay so bestie, welcome to mkosi-initrd(1) πΈ this one lives in the General Commands Manual section, and honestly? she's giving "small wrapper, big main character energy." β¨
π NAME π
mkosi-initrd β builds initrds or unified kernel images for the current system, using mkosi. yes, the current one. the one you're literally on right now. icon behavior tbh π
π¦ SYNOPSIS π¦
mkosi-initrd [options...]
that's it. that's the whole vibe. options go in, initrd comes out. π₯
β¨ DESCRIPTION β¨
so mkosi-initrd is a wrapper on top of mkosi β think of mkosi as the genius older sister and mkosi-initrd as the chill little sibling who handles the boring parts for you π«Ά
her whole job? simplifying the generation of initrds and Unified Kernel Images for the current running system. no cap, that's the entire mission statement. slay. π
π OPTIONS π
--kernel-version=,-kβ which kernel version do we look in for the kernel modules to include? π defaults to the kernel version of the running system (uname -r), because obviously we assume you like the one you booted. (note the=on the long form, bestie, it wants the value.)--format=,-tβ the output format, pick one:cpioβ a CPIO archiveukiβ a unified kernel image, with the image chilling in the.initrdPE sectiondirectoryβ generates the image directly in a local directory
defaults to cpio. periodt. π
--output=,-oβ the name to use for the generated output image file or directory (depends on your format, iykyk). defaults toinitrd.--output-dir=,-Oβ path to the directory where all the generated artifacts get placed. defaults to the current working directory, cute and simple π--generic,-gβ builds a generic initrd without host-specific kernel modules. the whole point: it should let your local system boot on different hardware π but β and this is the important but β it's still tied to the kernel version of the running system, or whatever you set with--kernel-version=. so, portable-ish. not fully untethered. know the difference bestie π--profile=β sets the profiles to enable for the initrd. by default, all profiles are disabled π and here's the menu:lvmβ enables support for LVMnetworkβ enables support for network viasystemd-networkdnfsβ enables support for NFS. heads up: it requires networking in the initrd, either via thenetworkprofile or some other custom method of your choosing π§pkcs11β enables support for PKCS#11plymouthβ provides a graphical interface at boot (animation + password prompt) πβ¨raidβ enables support for RAID arrays
--debugβ enable additional debugging output. more words! more info! π«Ά--debug-shellβ spawns a debug shell in the sandbox if a sandboxed command fails. very "when things go wrong, we go in" energy π--debug-sandboxβ runsmkosi-sandboxwithstrace. yes. that strace. peak investigative girlboss behavior π--show-documentation,-Dβ shows the man page formkosi-initrd. meta. love that for us π--show-summary,-Sβ shows the summary of configuration. a lil recap moment π--versionβ shows the package version. π·οΈ--help,-hβ shows brief usage information. the classic. the blueprint. the "help me help you" π«Ά
πΈ CONFIGURATION πΈ
okay so config for mkosi-initrd gets read from these directories, in increasing order of priority:
/usr/lib/usr/local/lib/run/etc
so yes, /etc wins. it always wins. main character directory fr π
under any of those directories you can use:
mkosi.conf.d/β for config filesmkosi.extra/β for extra files to include in the initrd- and so on β¨
for the full details, go read the Configuration Settings and FILES sections in mkosi(1). she has lore. π¦
for configuration files, use drop-ins β like /etc/mkosi-initrd/mkosi.conf.d/local.conf π that's the pattern, memorize it, it's giving "just put it in the right folder and everything works."
β SEE ALSO β
mkosi(1)β the big sister. go read her. π
and that's the page, bestie π«Ά signing off from the mkosi-initrd(1) manual page in the General Commands Manual β that footer is genuinely just mkosi-initrd(1), no date, no version stamp, that's the whole send-off, so consider this your official cute goodbyeeee πβ¨π
π¦ where this page comes from
- arch rolling: mkosi 27.1-1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms