Chapter 14: Managing Storage Flashcards
- Which tool do you use to create GUID partitions?
- gdisk is used to create GUID partitions.
- Which tool do you use to create MBR partitions?
- fdisk is used to create MBR partitions.
- What is the default file system on RHEL 8?
- XFS is the default file system on RHEL 8.
- What is the name of the file that is used to automatically mount partitions while booting?
- /etc/fstab is used to automatically mount partitions while booting.
- Which mount option do you use if you want a file system not to be mounted automatically while booting?
- The noauto mount option is used to specify a file system should not be mounted automatically while booting.
- Which command enables you to format a partition that has type 82 with the appropriate file system?
- mkswap enables you to format a partition that has type 82 with the appropriate file system.
- You have just added a couple of partitions for automatic mounting while booting. How can you safely test if this is going to work without actually rebooting?
- mount -a enables you to test, without actually rebooting, whether automatic mounting of the partitions while booting is going to work.
- Which file system is created if you use the mkfs command without any file system specification?
- Ext2 is created if you use the mkfs command without specifying a file system.
- How do you format an Ext4 partition?
- Use either mkfs.ext4 or mkfs -t ext4 to format an Ext4 partition.
- How do you find UUIDs for all devices on your computer?
- Use blkid to find UUIDs for all devices on your computer.
- Which of the following is not an advantage of using a GUID partition table over using an MBR partition table?
a. Access time to a directory is quicker.
b. A total amount of 8 ZiB can be addressed by a partition.
c. With GUID partitions, a backup copy of the partition table is created automatically.
d. There can be up to 128 partitions in total.
A.
In GPT, there is no longer a need to differentiate between primary, extended, and logical partitions; in fact, it is not even possible. Using logical
partitions is not an advantage due to the limited number of primary partitions available on MBR disks.
You want to create a partition with a size of 10245 bytes. What size should it be?
a. 1 PB
b. 1 PiB
c. 1 EB
d. 1 EiB
B. 1 pebibyte (PiB) is 1024 × 1024 × 1024 × 1024 × 1024 bytes.
Which partition type is commonly used to create a Linux partition?
a. 81
b. 82
c. 83
d. 8e
C.
Partition type 83 is normally used to create Linux partitions.
What is the default disk device name you would expect to see in KVM virtual machines?
a. /dev/sda
b. /dev/hda
c. /dev/sda
d. /dev/xsda
C.
KVM virtual machines use the virtio driver to address hard disks. This driver generates the device /dev/vda as the first disk device.
Which of the following statements is not true?
a. Do not ever use gdisk on an MBR disk.
b. fdisk offers support to manage GPT partitions as well.
c. Depending on your needs, you can create MBR and GPT partitions on the same disk.
d. If your server boots from EFI, you must use GPT partitions.
C.
A disk can have one partition table only. For that reason, it is not possible to
have MBR and GPT partitions on the same disk.
Which of the following file systems is used as the default in RHEL8?
a. Ext4
b. XFS
c. btrfs
d. Ext3
B.
XFS is used as the default file system; partitions can still be formatted with other file systems, like Ext4.
Which command enables you to find current UUIDs set to the file systems on your server?
a. mount
b. df -h
c. lsblk
d. blkid
D.
The blkid command shows all file systems, their UUID, and if applicable, their label.
What would you put in the device column of /etc/fstab to mount a file system based on its unique ID 42f419c4-633f-4ed7-b161-519a4dadd3da?
a. 42f419c4-633f-4ed7-b161-519a4dadd3da
b. /dev/42f419c4-633f-4ed7-b161-519a4dadd3da
c. ID=42f419c4-633f-4ed7-b161-519a4dadd3da
d. UUID=42f419c4-633f-4ed7-b161-519a4dadd3da
D.
To mount a file system based on its UUID, use UUID=nnnn in the /etc/fstab device column.
Which of the following /etc/fstab lines would perform a file system check on the file system, but only after the root file system has been checked
successfully?
a. /dev/sda1 /data xfs defaults 1 1
b. /dev/sda1 /data xfs defaults 1 2
c. /dev/sda1 /data xfs defaults 1 1
d. /dev/sda1 /data xfs defaults 0 2
B and D.
To check a file system upon boot, but only after the root file system has been checked successfully, put a 2 in the sixth column in /etc/fstab
Which mount option would you use in /etc/fstab to specify that the file system can be mounted only after the network is available?
a. network
b. _netdev
c. _network
d. netdev
B.
The _netdev mount option is used to specify that the file system depends on the network to be present before it can be mounted
- Add two partitions to your server. If possible, put them on the primary disk that is in use on your server. If that is not possible, use a second (virtual or
USB) disk to add these partitions. Create both partitions with a size of 100 MiB. One of these partitions must be configured as swap space; the other
partition must be formatted with an Ext4 file system. - Configure your server to automatically mount these partitions. Mount the Ext4 partition on /mounts/data and mount the swap partition as swap space.
- Reboot your server and verify that all is mounted correctly. In case of problems, read Chapter 18, “Essential Troubleshooting Skills,” for tips on
how to troubleshoot.
- fdisk /dev/sda;