Linux Storage u0026 Disk Management Quiz Quiz

Explore key concepts in Linux storage and disk management with questions covering filesystems, partitioning, mounting, storage devices, and disk utilities. This quiz helps reinforce your understanding of managing storage in a Linux environment for both personal and professional use.

  1. Identifying Partitioning Utilities

    Which Linux utility is commonly used for interactive disk partitioning, allowing you to create and delete disk partitions on devices such as /dev/sda?

    1. mount
    2. fdisk
    3. htop
    4. chmod

    Explanation: The 'fdisk' utility is designed for partitioning disks, enabling users to create, delete, or list partitions. 'chmod' manages permissions, not storage. 'mount' attaches file systems but cannot partition disks. 'htop' is a process viewer unrelated to disk management. Therefore, 'fdisk' is the correct choice for interactive disk partitioning.

  2. Mounting Filesystems

    Consider you have attached a new drive and formatted it; which command would you use to make its filesystem accessible at a directory like /mnt/data?

    1. ls
    2. useradd
    3. mount
    4. umask

    Explanation: The 'mount' command attaches a filesystem to a directory, making its contents available. 'ls' simply lists directory contents and cannot attach filesystems. 'umask' adjusts default permissions for new files, and 'useradd' is for creating users. Only 'mount' is for making a new drive accessible through a directory.

  3. Filesystem Types

    Suppose you want to format a new partition with a journaling filesystem commonly used in Linux; which filesystem type would you select?

    1. minix
    2. ntfs
    3. fat32
    4. ext4

    Explanation: The ext4 filesystem is a popular journaling filesystem in Linux, providing reliability and modern features. 'fat32' lacks journaling and is not ideal for Linux storage needs. 'ntfs' is primarily used by some other operating systems, and 'minix' is a simple, non-journaling filesystem. Thus, ext4 is the preferred journaling choice on Linux.

  4. Understanding Device Files

    In Linux, which device file typically represents the first connected SATA hard disk drive in the system?

    1. /media/cdrom
    2. /dev/tty0
    3. /dev/hdc
    4. /dev/sda

    Explanation: /dev/sda refers to the first SATA (or SCSI) hard disk in Linux systems. '/dev/hdc' usually signified the third IDE drive in legacy systems. '/media/cdrom' is a common mount point for optical drives, and '/dev/tty0' is a terminal device, not a storage device. Therefore, '/dev/sda' correctly identifies the first SATA disk.

  5. Disk Usage Analysis

    Which command provides a human-readable summary of available and used disk space on all mounted filesystems?

    1. mkdir
    2. ps aux
    3. lsblk -f
    4. df -h

    Explanation: 'df -h' displays disk space usage and availability in a human-readable format such as gigabytes or megabytes. 'ps aux' shows running processes, not disk usage. 'mkdir' creates directories and does not view storage. 'lsblk -f' shows block device details and filesystem type, but not detailed space usage. Thus, 'df -h' is the correct command for this purpose.