LPIC-2 Linux Kernel and System Startup Practice Question
Which TWO commands can be used to rebuild the initramfs on modern Linux systems? (Choose two.)
⚠ Common exam trap
Candidates often confuse `mkinitrd` (legacy) with `dracut` or `update-initramfs`, or mistakenly think `grub-mkconfig` rebuilds the initramfs when it only updates the bootloader menu.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
dracut -f
`dracut -f` forces the regeneration of the initramfs on modern Red Hat–based distributions (e.g., RHEL, CentOS, Fedora). Option C is correct because `update-initramfs -u` updates the initramfs on Debian/Ubuntu systems by rebuilding the current kernel's initramfs image. Both commands are the standard tools for rebuilding the initial RAM filesystem on their respective distributions.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
dracut -f
Why this is correct
Correct for Red Hat-based systems.
- ✗
mkinitrd
Why it's wrong here
mkinitrd is obsolete and not used on modern systems.
- ✓
update-initramfs -u
Why this is correct
Correct for Debian-based systems.
- ✗
grub-mkconfig
Why it's wrong here
grub-mkconfig regenerates GRUB configuration, not initramfs.
- ✗
mkinitramfs
Why it's wrong here
mkinitramfs is a low-level command, but update-initramfs is the preferred wrapper; mkinitramfs alone is not standard for all distros.
Visual reference
Go deeper
Related to this question
About these practice questions
This LPIC-2 question is part of Courseiva's 507-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This LPIC-2 practice question is part of Courseiva's free LPI certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LPIC-2 exam.