Challenge your understanding of Linux disk management tools, storage ecosystems, and key commands for partitioning and filesystem handling. This quiz helps you assess your practical knowledge of core disk utilities and concepts in Linux environments.
Which command can display the type of partition table present on a Linux disk, such as MBR or GPT, using a simple and widely-used utility?
Explanation: The 'fdisk' command is commonly used to manage disk partitions and can display the partition table type (such as MBR or GPT) when viewing a disk. 'mkdir' is for creating directories and does not deal with disks at all. 'df' is used for reporting disk space utilization but does not provide details about partition tables. 'chmod' changes file permissions and is unrelated to disk or partition management.
What Linux command can you use to display available and used disk space on mounted filesystems, for example to check how full the root partition is?
Explanation: 'df' provides a summary of available and used disk space on mounted filesystems, making it ideal for quickly checking partition usage. 'du' reports disk usage for files and directories, not partitions themselves. 'lsblk' lists block devices and their hierarchy but does not show usage statistics. 'cat' is used to display file content and is not related to disk space monitoring.
If you have a new disk partition at /dev/sdb1 and you want to prepare it for use by creating an ext4 filesystem, which command should you use?
Explanation: The correct command for formatting a partition with the ext4 filesystem is 'mkfs.ext4'. 'mount' attaches the filesystem for use but does not create one. 'fsck' checks and repairs filesystems that already exist but cannot create them. 'lsmod' lists kernel modules and is unrelated to filesystems or partitions.
To manage logical volumes in Linux, including creating and resizing them, which of the following commands is specifically designed for this purpose?
Explanation: 'lvcreate' is used within the logical volume manager to create logical volumes. 'fdak' appears to be a typographical error and is not a valid command. 'pvdisplay' shows information about physical volumes but cannot create logical volumes. 'swapoff' is used to deactivate swap space, unrelated to logical volume creation.
If you need to view a tree-like summary of attached block devices and their mountpoints in Linux, which command from the storage ecosystem provides this detailed overview?
Explanation: 'lsblk' is designed to display detailed information about block devices, their parents, partitions, and mountpoints in a hierarchical manner. 'lblsk' is a misspelled option and not a valid utility. 'dd' is for copying and converting data between files and devices, not for listing them. 'sync' is used to flush data to disk and does not provide device overviews.