LPIC-2 Practice Question: Block Devices, Filesystems and Advanced Storage
A server running Linux with an ext4 filesystem on /dev/sda1 has experienced an unexpected power loss due to a faulty power supply. After replacing the power supply and rebooting, the system fails to mount /dev/sda1 with an error message indicating 'wrong superblock magic number' or 'superblock corrupted'. The administrator recalls that ext4 filesystems have backup superblocks created during mkfs. Using the command 'dumpe2fs /dev/sda1 | grep -i backup' is not possible because the device is not mountable. However, the administrator remembers that for this specific filesystem, a backup superblock is located at block offset 32768 based on the output of 'mke2fs -n' from the original creation. What is the correct course of action to recover the filesystem and mount it?
⚠ Common exam trap
A common mix-up: candidates think `e2fsck -fy` can automatically fix any corruption, but it relies on a valid primary superblock; when the superblock is corrupted, you must explicitly specify a backup superblock location with the `-b` option.
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
✓
Run `fsck.ext4 -b 32768 /dev/sda1` to restore the superblock, then mount the filesystem.
`fsck.ext4 -b 32768` instructs the filesystem check utility to use the backup superblock located at block offset 32768, which is a known backup location for ext4 filesystems created with default settings. This allows `fsck` to read a valid superblock, repair the primary superblock, and make the filesystem mountable again without data loss.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Run `fsck.ext4 -b 32768 /dev/sda1` to restore the superblock, then mount the filesystem.
Why this is correct
This uses the backup superblock at block 32768 to repair the filesystem, allowing it to mount.
- ✗
Run `e2fsck -fy /dev/sda1` to force a filesystem check.
Why it's wrong here
e2fsck will use the default superblock, which is corrupted, so it will fail to perform a meaningful check.
- ✗
Run `dd if=/dev/zero of=/dev/sda1 bs=4k count=1` to zero the superblock, then create a new filesystem with mkfs.ext4.
Why it's wrong here
This destroys all data on the partition; it is not a recovery method.
- ✗
Run `tune2fs -j /dev/sda1` to add a journal to the filesystem.
Why it's wrong here
The filesystem already has a journal; this command does not fix a corrupted superblock.
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.