A user mounts a device to a mount point directory and realizes afterward they need files previously found within the mount point directory. What should this user do?
B. Unmount the device from the directory.
[Mounting a filesystem to a directory is nondestructive as it merely redirects users in that directory to the root of a filesystem on a device. After a device is unmounted from a directory, users will be able to access the original files and subfolders within that directory.]
A device file _____. (Choose all that apply.)
a. has no inode section
b. has no data section
c. displays a major and minor number in place of a file size
d. has a fixed size of 300 KB
b. has no data section
c. displays a major and minor number in place of a file size
[Device files are comprised of inodes only. As a result, they have no data section and instead display the major and minor number they refer to in place of a file size.]
A user runs the fsck command with the -f option on an ext4 filesystem that is showing signs of corruption. How would that user locate any files the system was unable to repair?
A. Mount the filesystem and check the lost+found directory underneath the mount point.
[Any files that the fsck command cannot repair are moved to the lost+found directory on the filesystem itself.]
What does the du -hs /var command do?
C. displays the total size of the /var directory
[The du command displays disk usage by directory. The -h option displays this usage in a human-readable format, while the -s option shows a summary of the total directory size.]
Character devices typically transfer data more quickly than block devices.
False
[Since block devices can transfer information block-by-block instead of character-by-character, they can transfer information faster than character devices.]
Jaime has just installed two new SAS SSDs in his system. He properly installs the hardware in his machine. Before he can use them for data storage and retrieval, what must he do? (Choose all that apply.)
D. Create one or more partitions on each of the SSDs.
e. Mount any partitions created on the two SSDs such that they are accessible by the operating system.
f. Format any partitions created on the SSDs with a valid filesystem recognized by Linux.
[After installing a new storage device, you must create at least one or more partitions on it, format the partitions with a filesystem, and then mount the filesystems to a mount point directory under the root directory (/).]
Which command is used to display the amount of free space that exists on a filesystem?
C. df
[The df command displays the amount of free and used space on each mounted filesystem.]
What does the command df –i do?
D. displays the number of used and available inodes on each mounted filesystem
[The -i option to the df command displays free and used inodes for each mounted filesystem.]
After a partition on a storage device is formatted with a filesystem, all partitions on that storage device must use the same filesystem.
False
[Each partition on a storage device can use a different filesystem, if desired.]
Which of the following statements are true? (Choose all that apply.)
a. Quotas can only limit user space.
b. Quotas can only limit the number of files a user can own.
c. Quotas can limit both user space and the number of files a user can own.
d. Hard limits can never be exceeded.
e. Hard limits allow a user to exceed them for a certain period of time.
f. Soft limits can never be exceeded.
g. Soft limits allow a user to exceed them for a certain period of time.
h. Either a hard limit or a soft limit can be set, but not both concurrently.
c. Quotas can limit both user space and the number of files a user can own.
d. Hard limits can never be exceeded.
g. Soft limits allow a user to exceed them for a certain period of time.
[Quota limits can be applied to both inodes (number of files and directories) and blocks (total size of files and directories). Hard quotas cannot be exceeded, while soft quotas can be exceeded for a period of time.]
Which of the following commands can only be used to create partitions on a GPT storage device?
B. gdisk
[The gdisk command can only be used to partition GPT devices.]
You want to see the filesystems that are in use on the system. What command could you use? (Choose all that apply.)
B. cat /etc/mtab
[The df command displays mounted filesystems using information from the /etc/mtab file.]
Which command mounts all existing filesystems in /etc/fstab?
D. mount -a
[The -a option to the mount command will mount all filesystems listed in /etc/fstab.]
Which command is used to format a partition on a hard disk drive with the ext4 filesystem?
A. e2mkfs –t ext4 device
[The e2mkfs command can be used to create an ext4 filesystem. All other commands listed in the answers do not exist.]
Given the following output from /etc/fstab, which filesystems will be automatically checked on boot by the fsck command?
/dev/sda1 /boot ext4 defaults 1 1
/dev/sda2 swap swap defaults 1 0
/dev/sda3 / ext4 defaults 0 1
/dev/sda4 /var ext4 defaults 1 0
/dev/sda1 /home ext4 defaults 0 1
/dev/sr0 /media/dvd iso9660 noauto,ro 0 0
B. /, /boot, and /home
[A 1 in the sixth field indicates that the filesystem will be checked using the fsck command by default.]
The lvextend command can be used to add unused space within a volume group to an existing logical volume.
True
[You can use the lvextend command to extend the size of a logical volume, provided there is sufficient free space available within a volume group.]
What must you do to successfully run the fsck command on a filesystem?
C. Unmount the filesystem.
[To check a filesystem for errors using fsck, you must first unmount the filesystem.]
You plug a USB flash drive into a system that has two SATA hard disk drives. How will the partition on this USB flash drive be identified by Linux?
D. /dev/sdc1
[The first and second SATA hard disk drive will be recognized as sda and sdb, respectively. Thus, a USB flash drive will take the next available device file (/dev/sdc) and the first partition on that drive will be /dev/sdc1.]
Which command can be used to repair an XFS filesystem?
B. xfs_repair /dev/sdb1
[You can use the xfs_repair command to repair an XFS filesystem.]
Which of the following statements regarding LVM structure is correct?
C. VGs are comprised of one or more PVs.
[Volume groups (VGs) are pools of storage that are made up of individual physical volumes (PVs). Logical volumes (LVs) are created from the free space within VGs.]