8 Disk and File System Management
Which of the following repquota options will give you quota limits and disk usage for all file systems listed in /etc/mtab?
-a
You are inspecting the superblocks and block information on your file system. You need dumpe2fs to display only the blocks that are reserved as bad in the file system. Which of the following options should you use?
-b
Your ext3 file system has experienced a significant amount of corruption. To examine the file system, you want to use the debugfs utility. Which of the following debugfs options should you use to examine the file system?
-c
You have a critical file called yearend.xls. You have set the file permissions so that only the owner of the file can modify it, and only group owners can read it. Which of the following file listings show that you have set the permissions correctly?
-rw-r----- 1 george acctg 26256 June 1 04:16 yearend.xls
What is the file path and name of the directory that contains device files for hard drives, optical drives, and USB devices?
/dev
You need to configure your Linux system to allow only the root user account to mount the CD-ROM device. Which of the following options should you add to the /etc/fstab file?
/dev/cdrom /media/cdrom -t iso9660 ro,nouser,noauto
Enter the full device file name for the second partition on the hard drive with the lowest ID number.
/dev/sda2
Type the full device file name for the first partition on the hard drive with the third lowest ID number.
/dev/sdc1
You need to implement disk quotas on your Linux system for the / directory. What is the full path and name of the file that must be edited to implement quotas for users and groups?
/etc/fstab
What file shows the currently mounted volumes?
/etc/mtab
Which of the following directories is specified by Filesystem Hierarchy Standard (FHS) as a mount point for removable media, such as USB storage media, DVDs, and CD-ROMs?
/media
You have just inserted a thumb drive into your Linux server and now want to view the contents of the thumb drive. Where is the MOST likely place you can find the mounted thumb drive in the Linux file system?
/run/media/<username>
Which of the following hexadecimal codes represents an extended partition?
0x85
Which of the following is the maximum number of GUID partitions that can be created using the gdisk utility?
128
Which of the following is the maximum number of primary partitions that can be created on a single hard disk drive?
4
Which of the following sets of octal permissions would allow everyone to execute the following file as if they were the root user? -rwxr-xr-x 1 root root 8045 July 24 2018 myscript
4755
You are called into the office of a newly hired manager. The manager has copied a file from his old place of work onto his new workstation but is now receiving an error message that access is denied each time they try to access the file. The manager is not the owner of the file or a member of the group the file is associated with. Which of the following represents the LEAST set of file permissions needed for the manager to be able to read and write to the file?
666
Which of the following MOST accurately describes Redundant Array of Independent Disks (RAID)?
A disk subsystem that combines multiple physical disks into a single logical storage unit.
Which of the following statements best describes the function of the repquota /home -vu command?
A summary of disk usage and quotas is displayed for the users who have files within /home.
Gloria, a Linux administrator, used the gdisk utility to create eight partitions on a new hard drive. Which of the following BEST describes the partitions Gloria has created?
All eight partitions are the same. They are simply partitions. There are no primary, extended, or logical partitions.
Which of the following are the advantages of using GPT instead of MBR for partitioning a storage device? (Select two.)
Allows up to 128 partitions on a storage device. Uses only one type of partition.
As a Linux administrator, you have installed a new hard disk. You create two primary partitions, sdb1 and sdb2, and one extended partition, sdb3. You format sdb1 with ext3 and sdb2 as a swap area. When you attempt to format sdb3 as a swap area, you are unable to do so. Which of the following explains why you can't format sdb3?
An extended partition can't be formatted.
The setfacl command lets you set the access control list (ACL) for files and directories and includes several options. Drag the setfacl option on the left to the correct description on the right.
Apply operations to all files and directories recursively. R Print the version of setfacl, and exit. v All operations are applied to the Default ACL. d Remove ACL entries. x Modifies the ACL of a file or directory. m Removes the Default ACL. k Removes all extended ACL entries. b
You are asked to help a user complaining that file system errors are being reported during boot-up. When you reboot the user's system, you see errors on sda2. Which of the following strategies will check the file system on sda2 and fix the errors?
Change to single-user mode and run fsck /dev/sda2.
Which of the following describes the effects of using the tune2fs -j /dev/sdb1 command?
Converts the /dev/sdb1 device to ext3.
Which of the following steps must be completed after creating a logical volume so that the logical volume can be used to store files?
Create file systems on the volumes and mount them.
Once you enter the gdisk utility, you can enter several options to perform specific partitioning tasks. Drag a gdisk option on the left to its correct task description on the right.
Creates a new GUID partiton table. o Writes changes to the partition table. w Changes a partition's type code. t Adds a new partition. n Deletes a partition. d Displays detailed partition information. i Changes a partition's name. c
Which of the following I/O schedulers uses the I/O request time stamp to push I/O requests that have reached their deadline to the highest priority for processing?
Deadline
The system requirements for a new Linux computer show that the system will primarily be used to store documents of small size. Which of the following file systems would be the MOST efficient at storing these documents on a Linux system?
EXT4
Yesterday, you created a new swap area for your system. Today, after rebooting the system, you find that the swap area is not mounted. What should you do to ensure the swap area is mounted each time the system boots?
Edit /etc/fstab and add the swap partition.
You attempt to unmount a volume using the umount /dev/sdd3 command, but you receive a device is busy error message. Which of the following strategies will be MOST likely to allow you to unmount the file system? (Select two.)
Ensure your current working directory is not on the file system, and try to unmount again. Find and close any open files on the file system, and try to unmount again.
What is the standard used by Linux distributions to determine the layout of files and folders in the Linux system?
Filesystem Hierarchy Standard (FHS)
You are running the sandboxed AppImages application on your Linux system, which keeps the application from compromising your Linux filesystem by leaving kernel access to a separate kernel module. Which of the following technologies provides this type of security for the AppImages application?
Filesystem in USErspace (FUSE)
What is the impact to the customer_list file by entering the setfacl -m u:gsmith:r customer_list at the command prompt?
It grants the user gsmith read access to the customer_list file.
The getfacl command lets you display the filename, owner, group, and access control list (ACL) for a file and includes several options. Drag the getfacl option on the left to the correct description on the right.
Lists the ACLs of all files and directories recursively. R Lists numeric user and group IDs. n Skips files that only have the base ACL entries (owner, group, others). s Displays the default access control list. d Displays the file access control list. a Prints all effective rights comments. e Prints the version of getfacl and exit. v
A file system inode indicates where a file's data physically exists on a disk. What other information does an inode contain? (Select two.)
Modification, access, and creation times Permissions
Which of the following are the PRIMARY tasks you can perform with the mount command? (Select two.)
Mount a file system on a storage device in a root file system tree. List all file systems that are currently mounted.
Which of the following are types of remotely connected devices?
Network Attached Storage (NAS) Storage Area Network (SAN)
The RAID configuration you are using to combine several hard drives into a single logical volume includes the following benefits and requirements: *Provides fault tolerance for a single disk failure. *Provides redundancy and performance. *Uses 50% of the total raw capacity of the drives due to mirroring. *Requires a minimum of four disks. What is the RAID level you are using for your logical volume?
RAID 10
You are using RAID to combine several hard disks on a Linux server into a single logical storage unit. You have configured the RAID volume to combines disk striping across multiple disks with parity for data redundancy. The parity information is stored on each disk. If a single disk fails, its data can be recovered using the parity information stored on the remaining disks. Which of the following RAID levels are you using?
RAID 5
Which of the following is a requirement for ALL configurations of RAID?
The amount of disk space used on each disk must be of equal size.
Roberto, a help desk technician, receives a call from an employee who is not able to change to a directory that they own. The following is the output from the commands that the employee entered: [sally@linux ~]$ ls -aldrw-rw-rw-. 2 sally sally 6 Mar 14 16:08 Reports[sally@linux ~]$ cd Reports/bash: cd: Reports/: Permission denied[sally@linux -]$ Based on the output, which of the following describes the problem?
The employee does not have the eXecute permission as owner of the directory.
When using the parted command instead of the gdisk utility, which of the following is important to remember?
The parted command writes partition changes to disk immediately.
Which of the following is the maximum number of logical partitions allowed on an extended partition?
Unlimited
Which file system is a FAT32 file system for Linux?
VFAT
You need to see who has permissions to the promotions_annual file. You use ls -l promotions_annual and receive the following information: drwxr-xr-x 22 dmartinez hr 4096 Jun 19 15:01 promotions_annual
Which user owns this file? (Your answer is case-sensitive.) dmartinez Which group owns this file? (Your answer is case-sensitive.) hr
You need to see who has permissions to the sales_projection_q2 file. You use ls -l sales_projection_q2 and receive the following information: drwxr-xr-x 22 pclark acct 4096 Jun 19 15:01 sales_projection_q2
Which user owns this file? (Your answer is case-sensitive.) pclark Which group owns this file? (Your answer is case-sensitive.) acct
You want to change the name of a partition on the sdc storage device. You have already entered gdisk /dev/sdc to begin the editing process. Which of the following gdisk options can you enter to change the partition name?
c
You have entered the cat /sys/block/sdb/queue/scheduler command to find out which I/O scheduler is currently being used by your Linux system. The following is displayed: noop [cfq] deadline Which I/O scheduler is currently being used by your Linux system?
cfq What I/O schedulers are available on your Linux system? noop, cfq, deadline
What would you enter at the command prompt to change the group ownership to finance for the report01.png file in the /sales/reports directory?
chgrp finance /sales/reports/report01.png
What would you enter at the command prompt to change the group ownership for the devstyle.txt file to rand in the present working directory?
chgrp rand devstyle.txt
You need to change ownership of a script called myscript so that only the user owner has read/write access to it and only the user owner and group owner have execute permissions. Which of the following commands will accomplish this task?
chmod 750 myscript
The following are the permissions currently assigned to the customer_list file: -rwxr-xr-x 1 mfoote finance 8045 July 24 2022 customer_list You want to add the write permission for the finance group and remove all permissions for others. Which of the following commands would accomplish this task?
chmod g+w,o-r,o-x customer_list
Which of the following commands would you use to make nstevens the owner of all of the files and directories in the /docs directory?
chown -R nstevens /docs
The Human Resources director for your company has been given an expanded role that covers internal training courses for the company. All the internal training course files are located in the /training/int directory. The director (pmadison) has requested ownership of all these files. Which of the following commands would you use to make pmadison the owner of all the files and directories in the /training/int directory?
chown -R pmadison /training/int
Which of the following commands make sales the group owner of the /sales/report file? (Select two.)
chown .sales /sales/report chown :sales /sales/report
The packaging department for your import/export company has recently been moved to the shipping department. In addition, all the packaging department employees have been moved to the shipping group. You would now like to make shipping the owner of the /packaging/personnel.png file. Which of the following commands could you enter to perform this task? (Select two.)
chown .shipping /packaging/personnel.png chown :shipping /packaging/personnel.png
You use ls -l /home/sales/sales_projection_q2 and receive the following information: drwxr-xr-x 22 pclark acct 4096 Jun 19 15:01 sales_projection_q2 Which of the following commands will change the user owner to jyoung and the group owner to sales?
chown jyoung:sales /home/sales/sales_projection_q2
When creating an ext2 or ext3 file system, a fixed number of inodes is assigned. Which of the following commands shows the number of inodes, number of free inodes, and number of used inodes?
df -i
What command would you enter at the command prompt to list all files and directories in the badams home directory, along with file size and the total amount of space taken up by the directory?
du -ac /home/badams
Which of the following commands allows you to use an alternative superblock when the primary superblock has been corrupted?
e2fsck -b 16385 /dev/sda1
Which of the following commands will open the quota file for a specific user?
edquota -u
Which command should you enter at the command prompt to change the quota settings for the gshant user?
edquota -u gshant
Which of the following Linux file systems support journaling?
ext4
Which of the following is the MOST common Linux file system?
ext4
Which of the following commands/command sequences can you use to view the partition information on the first hard disk? (Select two.)
fdisk /dev/sda, then press p fdisk -l
Which of the following commands partitions the second hard disk on a Linux system?
fdisk /dev/sdb
Which partition management utility can be used to define and change various GUID partition configurations without committing the configuration to the disk until the w command is used?
gdisk
You have installed a new blank hard drive on your Linux system. This is the second drive on the system, so it is represented in the file system by the /dev/sdb file. You need to create GUID partitions on this drive. What command do you use to start the GUID disk management utility to create partitions on the /dev/sdb drive?
gdisk /dev/sdb
Which of the following commands displays the filename, owner, group, and access control list for the mynotes file?
getfacl mynotes
Which of the following commands creates a logical volume named video from the home volume group and configures it with 2 TB of disk space?
lvcreate -L 2T -n video home
Which of the following commands extends the graphics logical volume to a total of 20 Gigabytes?
lvextend -L 20G graphics
You are using LVM on your Linux system to manage the existing volumes. What command do you enter to scan for logical volumes on the system?
lvscan
Which of the following utilities is used to manage and monitor software RAID devices?
mdadm
Which of the following commands formats the second partition on the fourth disk drive with the ext3 file system?
mke2fs -j /dev/sdd2
You need to create an ext4 file system on the first partition on the second hard disk drive. What command should you enter at the command prompt?
mkfs.ext4 /dev/sdb1
One of the Linux servers for the accounting department needs additional memory to fix recent performance issues. You have ordered the memory, but it is backordered, so you decide to add a swap partition to the server to help with the performance issues immediately. Which of the following commands will add a swap partition to the first partition on the third hard drive?
mkswap /dev/sdc1
A user is trying to access a file system mounted at /mnt/sdb1, but receives an error that states No such file or directory. Which commands can you use to see the current mount points? (Select two.)
mount df
A number of new file systems have been added to a Linux server and you want to activate them. You also do not want to bring the server down. What command will activate the file systems without bringing the server down?
mount -a
You need to mount the CD-ROM device to the /media/cdrom directory. What command should you enter at the command prompt?
mount /dev/cdrom /media/cdrom
You have partitioned and formatted a new sdc hard drive. You want to mount the first partition on sdc to directory /mnt/newdisk. Which command will perform the mount correctly?
mount /dev/sdc1 /mnt/newdisk
What is the name of the partition management utility that will create both GUID partitions and file systems on those partitions?
parted
You want to create a standard Linux partition on your new hard drive that starts at 1 GB and ends at 21 GB. Which of the following commands should you enter to create the new partition?
parted mkpart Linux 1024 21504
Marco recently made some partition changes, and the kernel is not recognizing the partitions. Which of the following commands should Marco use to resolve the problem?
partprobe
Which of the following commands initializes a physical volume?
pvcreate
You have added a third hard disk to your Linux system. What command would you use to initialize a physical volume on this disk for later use by the Logical Volume Manager?
pvcreate /dev/sdc
You are using LVM on your Linux system to manage hard disk partitions. What command can you enter to scan for physical volumes on the system?
pvscan
What is the name of the package that must be installed if you want to use disk quotas on your Linux system?
quota
Which command should you enter at the command prompt to display the current user's quota limits and disk usage?
quota
Which of the following commands displays the disk usage and quota limits for the development group?
quota -g development
Which of the following commands creates the aquota.user and aquota.group files in your file system after creating the quota entries in /etc/fstab?
quotacheck -mavug
After creating the aquota.user and aquota.group files in the /home directory, what command should you enter to enable quotas for the /home directory?
quotaon /home
Which of the following sets of permissions represent the minimal permissions required to allow a user to list the contents of a directory?
r-x
You want to save the details of the new array to a file for configuration at boot. Which of the following commands would you use?
sudo mdadm --detail --scan | sudo tee -a /etc/mdadm/mdadm.conf
You have a Linux system with two activated swap partitions, sda3 and sdb2. Which of the following commands can you use to deactivate only the sda3 swap partition?
swapoff /dev/sda3
You have created a swap area on sda3, but it is not activated. What command will activate this swap partition?
swapon /dev/sda3
Partition /dev/sdb2 is mounted to /mnt/temp. You need to unmount /dev/sdb2. Which of the following commands can you use to unmount the partition? (Select two.)
umount /mnt/temp umount /dev/sdb2
Which of the following commands creates a volume group named backup and initializes it by adding the third disk in a Linux system to the volume group?
vgcreate backup /dev/sdc
You are using LVM on your Linux system to manage the existing volumes. After adding and initializing the fourth hard drive to the system and creating a physical volume, what command should you use to add it to the backup volume group?
vgextend backup /dev/sdd
You have an XFS file system in your Linux computer. You need to display the XFS file system parameters, such as the block size and inode data structures. Which of the following commands can you use to display the file system parameters? (Select two.)
xfs_info xfs_growfs -n