Title: IT / LPIC 101 Q/A / 4 Devices, Filesystems, FHS

Q: Which option best describes the following output from the ls -la command:
lrwxrwxrwx. 1 root root 35 Jul 8 2014 .fetchmailrc -> .configs/fetchmail/.fetchmailrc?
It is a file called .fetchmailrc that is linked using a symbolic link.
It is a file called .configs/fetchmail/.fetchmailrc that is owned by lrwxrwxrwx.
It is a directory called .fetchmailrc that is owned by user Jul.
It is a local directory called .configs/fetchmail/.fetchmailrc.
A: A. The listing shows a symbolic linked file located in the current directory, linked to .configs/fetchmail/.fetchmailrc. The file is owned by the root user and root group and was created on July 8, 2014.

Q: Assuming that a USB disk contains a single partition and is made available on /dev/sdb, which command mounts the disk in /media/usb?
mount /dev/sdb1 /media/usb
usbconnect /dev/sdb0 /media/usb
mount /dev/sdb0 /media/usb
usbmount /dev/sdb1 /media/usb
A: A. The mount command is used to mount drives in Linux. The source and destination mount points are expected as arguments. Drive partitions begin at the number 1, making the first partition number 1.

Q: Which option within a partition-mounting command will cause the partition to be mounted in such a way as to prevent execution of programs?
execless
stoprun
noexec
norun
A: C. The noexec option will prevent programs from being executed that reside on the partition. The noexec option is used frequently for mounting the /tmp partition.

Q: When working with partitions on disk, you see the type 0x82. Which type of partition is this?
Linux
Linux swap
NTFS
FAT
A: B. 0x82 is Linux swap, and 0x83 is Linux. NTFS is 0x07, and FAT is 0.0c.

Q: Which partition type should be created for a Linux system, non-swap partition?
82
83
84
L
A: B. The partition type 0x83 should be created for a normal Linux partition. Type 82 is used for swap; 84 is an OS/2 partition. There is no L type.

Q: Which command can be used to determine the location of a given executable that would be run if typed from your current environment and location?
which
what
whatis
when
A: A. The which command returns the full path to the given command and is useful for determining both whether a given command is available and the location from which the command will run.

Q: Which of the following commands will correctly change the group ownership of the file called a.out to users?
chgrp users a.out
chgrp a.out users
groupchg a.out users
grpchg users a.out
A: A. The chgrp command can be used to change group ownership of a file. The order is chgrp <groupname> <target>.

Q: Another administrator made a change to one of the local scripts used for administrative purposes. The change was also immediately reflected in your copy of the script. However, when examining the file with ls, you see that it appears to be a normal file. What is the likely cause of such a scenario?
The file was executed after edit.
The administrator copied the file to yours.
Your file is a hard link to the original.
The file has been restored from backup.
A: C. The file is almost certainly a hard link to the original script. Although ls won’t show this information, the stat command will show that it is a link and also show the inode to which the file is linked.

Q: Which of the following commands shows the usage of inodes across all filesystems?
df -i
ls -i
du -i
dm -i
A: A. The -i option to df produces information on inodes across all filesystems. The ls -i option will produce inode listings, but only for the current directory. The -i option is invalid for du, and dm does not exist as a command.

Q: You’re running fsck on an ext3 filesystem, and the process is taking longer than expected and requiring input from the administrator to fix issues. What option could be added to fsck next time so that the command will automatically attempt to fix errors without intervention?
-o
-V
-y
-f
A: C. The -y option will attempt to repair automatically, essentially answering y or yes instead of prompting. Of the other options, only -V is valid and will produce verbose output.

Q: Which of the following describes a primary difference between ext2 and ext3 filesystems?
ext3 was primarily a bug fix update to ext2.
ext3 includes journaling for the filesystem.
ext3 completely changed the tools needed for management of the disks.
ext3 filesystems have no significant differences.
A: B. The addition of journaling in ext3 increased filesystem reliability and performance.

Q: Which option to umask will display the permissions to be used in a Portable Operating System Interface (POSIX) format?
-P
-p
-S
-v
A: C. The -S option displays output in a format such as u=rwx,g=rx,o=rx. The other options listed do not perform the desired operation.

Q: Which option to ln creates a symlink to another file?
-sl
-s
-l
--ln
A: B. The -s option to ln creates a symbolic link, or symlink.

Q: Which of the following commands can be used if you need to locate various elements of a given command, such as its binaries and man pages?
whatis
find
whereis
ls
A: C. The whereis command displays pertinent information about the command given as its argument. For example, entering whereis apache2 on a Debian system will show the binary location, configuration file location, and other relevant details.

Q: Which option in /etc/updatedb.conf will remove a path from inclusion in the results?
PRUNEPATHS
EXCLUDEPATHS
INCLUDEEXCLUDE
SEPARATEPATH
A: A. The PRUNEPATHS option accepts a space-separated list of paths to remove from the results. The other options listed do not exist.

Q: According to the filesystem hierarchy standard (FHS), what is the correct location for site-specific data for a server?
/etc
/var
/tmp
/srv
A: D. The /srv hierarchy is used for data for server programs. The /etc hierarchy is configuration information; /var is also data files but variable, such as mail files. The /tmp directory is for temporary files.

Q: Which of the following commands enables the sticky bit for a user on a file called homescript.sh?
chmod +sticky homescript.sh
chmod 755 homescript.sh
chmod u+s homescript.sh
chown u+sticky homescript.sh
A: C. The chmod command is used for this purpose, and the u+s option sets the sticky bit for the user on the specified target.

Q: Which option to the mount command will mount all filesystems that are currently available in /etc/fstab?
-g
-a
-r
-y
A: B. The -a option mounts all filesystems in /etc/fstab that are currently available. This option is typically used if the mount points are not mounted at boot time or another mount point is added to the system after it has been booted.

Q: Which command is used to format a swap partition?
fdisk
mkswap
formatswap
format -s
A: B. The mkswap command formats a swap partition. The fdisk command is used to create the partition itself but not format it. The other two options do not exist.

Q: Which command and option is used to display the number of times that a filesystem has been mounted?
tune2fs -l
cat /etc/fstab
mount -a
less /etc/fsmnt
A: A. The tune2fs command displays a lot of information about filesystems, and when used with the -l option, the output includes the number of times that the filesystem has been mounted.

Q: Which option to xfs_metadump displays a progress indicator?
-g
-p
-f
-v
A: A. The -g option displays progress of the dump. The other options listed do not exist.

Q: The system is running out of disk space within the home directory partition and quotas have not been enabled. Which command can you use to determine the directories that might contain large files?
du
df
ls
locate
A: A. The du command will report on disk usage in a recursive manner, unlike the other commands shown here.

Q: Which file contains information about the filesystems to mount, their partitions, and the options that should be used to mount them?
/etc/filesystems
/etc/mounts
/etc/fstab
/srv/mounts
A: C. The /etc/fstab file is used to store information about the filesystems to mount within the system.

Q: According to the FHS, what is the proper mount point for removable media?
/etc
/srv
/tmp
/media
A: D. The /media mount point is used for removable media. See https://wiki .linuxfoundation.org/lsb/fhs-30 for more information on the FHS.

Q: Which file contains information on currently mounted filesystems, including their mount options?
/etc/mtab
/etc/fstab
/tmp/files
/etc/filesystems
A: A. The /etc/mtab file contains currently mounted filesystems. Note that /etc/fstab contains filesystem information but doesn’t report which filesystems are currently mounted.

Q: Which option to umount will cause the command to attempt to remount the filesystem in read-only mode if the unmounting process fails?
-o
-r
-f
-v
A: B. The -r option causes umount to attempt to remount in read-only mode. The -v option is verbose mode, and the -f option forces the operation. The -o option does not exist.

Q: The umask reports as 022. What is the permission that will be in effect for a newly nonexecutable created file?
u+rw, g+r, w+r
755
022
a+r
A: A. The 022 umask will translate into 644 permissions on a new nonexecutable file.

Q: The locate command is reporting out-of-date information. Which command should be run in order to have the locate command update its database?
locatedb -u
locate -u
updatedb
updatelocate
A: C. The updatedb command will update the database used by the locate command.

Q: Which shell built-in command can be used to determine what command will be run?
type
when
find
help
A: A. The type built-in returns the location that the shell will use in order to run the given command. The find command cannot be used for this purpose, and the other commands do not exist.

Q: Which option to chown recursively changes the ownership?
-f
-R
-a
-m
A: B. The -R option will perform the change ownership in a recursive manner.

Q: Which of the following represents the correct format for the /etc/fstab file?
<directory> <device> <type> <options>
<device> <type> <options>
<device> <type> <options> <directory> <dump> <fsck>
<filesystem> <mount point> <type> <options> <dump> <pass>
A: D. The proper order is the device (UUID or partition) or filesystem to mount, followed by the mount point or directory to mount that device, followed by its type and options, and then the dump and pass settings.

Q: Which of the following commands is used to identify the UUID for partitions?
blkid
ls
find
cat
A: A. The blkid command will show partition UUIDs. You can also get this information with the lsblk -no UUID <partition> command. The other commands shown in this question do not accomplish the required task.

Q: Which of the following describes the priority order for configuration files with systemd?
Files in /etc/, files in /run, and then files in /lib
Files in /run, files in /etc/, and then files in /lib
Files in /lib, files in /run, and then files in /etc
Files in /lib, files in /etc, and then files in /run
A: A. Priority order for systemd configuration files are those within the /etc/ hierarchy, followed by files in the /run/ hierarchy, followed by files in the /lib/ hierarchy.

Q: Which options to the fsck command will find and automatically assume that it should repair errors that it finds?
-y
-vy
-my
-xy
A: A. The -y option causes fsck to assume yes instead of prompting when repairing a filesystem. The -v option is verbosity. There is no -m or -x option for fsck.

Q: Which option to mke2fs sets the type of filesystem to be created?
-F
-a
-t
-e
A: C. The -t option sets the filesystem type as ext2, ext3, or ext4. The mke2fs command is typically symlinked from /sbin/mkfs.ext2, /sbin/mkfs.ext3, and /sbin/mkfs.ext4. The -F option forces mke2fs to create a filesystem, and the -a and -e options do not exist.

Q: Which of the following files is the default configuration file for the autofs automounter?
/etc/autofs
/etc/auto.master
/etc/autofs.conf
/etc/automounter.conf
A: B. The file /etc/auto.master contains the configuration for autofs. The other files listed as options are not valid for this scenario.

Q: Which of the following commands is used to create an ISO filesystem?
mkiso
mkfsiso
mkisofs
isofs-mk
A: C. The mkisofs command creates an ISO filesystem, which can then be written to a CD or DVD. The other commands listed are not valid.

Q: Which option to the tune2fs command sets the maximum mount count before the system will automatically run fsck on the partition on boot?
-b
-c
-C
-a
A: B. The -c option sets the maximum mount count. The -C option sets the current number of mounts. The -b and -a options do not exist.

Q: Which option to the mount command can be used to simulate the mount process without actually mounting the filesystem?
-q
-v
-l
-f
A: D. The -f option, also known as fake, is helpful for situations where you need to debug the mount process or when you need to add an entry to /etc/mtab for a previously mounted filesystem. The -l option shows labels, and -v is verbose. There is no -q option.

Q: When viewing /proc/mounts, you see a filesystem with the letters ro in the fourth column. To what do the letters ro refer?
relative option
realtime option
read-only
relative-only
A: C. The letters ro indicate that the filesystem has been mounted read-only, meaning that it is not possible to perform a write to the filesystem. The other possible option is rw, indicating that the filesystem has been mounted read-write.

Q: Which option to dumpe2fs displays the bad blocks for a given partition?
-bb
-C
-b
-f
A: C. Bad blocks are shown with the -b option. The -f option forces dumpe2fs to perform the requested operation, and the other command options do not exist.

Q: Which of the following filesystem types features copy-on-write?
ext3
ext4
FAT
Btrfs
A: D. Btrfs is based on the copy-on-write principle and is generally considered more advanced than ext4 and its predecessors. FAT is a legacy filesystem primarily used for DOS and its follow-ons like Windows.

Q: Which of the following commands displays filesystem geometry for an XFS filesystem?
xfsinfo
xfs_info
xfs -info
xfs --info
A: B. The xfs_info command, which is functionally equivalent to xfs_grow -n, displays information about an XFS-formatted filesystem.

Q: Which of the following commands can be used to display information such as the UUID for partitions on a system?
blkid
blockdev
devinfo
uuidinfo
A: A. The blkid command shows information about partitions including their type, their UUID, and other basic information. The other commands shown do not exist.

Q: Which option to the umount command will cause it to unmount only filesystems of the specified type?
-v
-f
-t
-a
A: C. The -t option, which can accept a comma-separated list of types, specifies that only filesystems of the listed type are to be unmounted. This is useful in conjunction with the -a option, which unmounts all filesystems except /proc. The -v option is verbose, and -f forces the operation to continue.

Q: Which command causes unwritten data to be written to disk immediately?
write
wrnow
connwrite
sync
A: D. The sync command writes unwritten data to the disk immediately and is useful to run just prior to attempting an unmount operation.

Q: Which option to xfs_check is used to verify a filesystem that is stored in a file?
-v
-a
-f
-d
A: C. The -f option specifies that xfs_check should check the contents of the named file for consistency. The -v option sets verbosity, and there is no -d or -a option.

Q: Which option to debugfs causes the filesystem to be opened in read-write mode rather than the default read-only?
-rw
-w
-r
-n
A: B. The -w option causes debugfs to open the filesystem in read-write mode. There is also a -c option to open in catastrophic mode for filesystems with significant damage. The -rw, -r, and -n options are not valid.

Q: Which daemon is responsible for monitoring Self-Monitoring, Analysis, and Reporting Technology (SMART)-compatible hard drives?
smartmon
smarty
sartd
smartd
A: D. The smartd daemon monitors SMART-compatible disks for notable events and can be configured to send alerts when events occur. The other commands listed are not valid for this scenario.

Q: When checking an ext3 filesystem, which option to the fsck.ext3 command causes it to run the check even if the filesystem is apparently marked as clean?
–f
-m
-a
-c
A: A. The -f option forces fsck to run on an otherwise clean filesystem for ext3 filesystems. This can be helpful for times when you suspect there is an error on the filesystem and need to verify the integrity of the filesystem as part of the troubleshooting process. This can also be helpful to prepare the filesystem for conversion, such as might be the case with a tool like btrfs-convert.

Q: You are performing an xfsrestore. The xfsdump was executed with a block size of 4MB. Which option do you need to invoke on xfsrestore in order for it to successfully use this dump?
-b 4M
-g 1M
-i 1M
-k 1028K
A: A. The block size for import or restore must match the block size used on export or dump. Block size is specified with the -b option, making option A correct. The other options are not valid for xfsrestore.

Q: You see the word defaults within /etc/fstab. Which options are encompassed within the defaults?
ro, exec, auto
rw, suid, dev, exec, auto, nouser, async
rw, exec, auto, nouser, async
rw, exec, nouser, async, noauto, suid
A: B. A filesystem with the word defaults for its mount options will be mounted read-write (rw), suid, with the ability to have executables (exec). The filesystem will be auto-mounted (auto), but users will not be able to mount it (nouser). Character and block special devices will be interpreted (dev), and operations on the disk will be performed in an asynchronous manner (async).

Q: Which of the following commands creates a btrfs subvolume?
btrfs create subvolume
btrfs subvolume create
btrfs sv create
btrfs svcreate
A: B. The btrfs subvolume create command creates a btrfs subvolume. The other commands are not valid.

Q: Which of the following options to xfsdump sets the maximum size for files to be included in the dump?
-p
-s
-z
-b
A: C. The -z option sets the maximum size for files to be included in the dump. The -b option sets the block size but is not related to what is being asked for in this scenario. The –s option sets the path for inclusion in the dump, and -p sets the interval for progress indicators.

Q: Which option to the tune2fs command sets the behavior when a filesystem error occurs?
-f
-d
-e
-k
A: C. The -e option sets the behavior, such as continue, remount read-only, or panic, when an error occurs at the filesystem level. The -f option forces whatever operation you’re requesting to continue even if there are errors. The -d and -k options are not valid.

Q: The /etc filesystem has been mounted as a read-only for a recovery process. You need to mount another partition. Which option to the mount command causes it to not write to /etc/mtab?
-a
-m
-b
-n
A: D. The -n option causes mount to not write to /etc/mtab and is particularly useful for the scenario described. The -a option mounts all filesystems in /etc/fstab. There is no -b or -a option.

Q: Which of the following commands deactivates swap space?
swapoff
swap -off
unmountswap
uswap
A: A. The swapoff command deactivates swap space, thereby making it unavailable as virtual memory on the system. The other commands shown as options are not valid.

Q: Within the [mount] section of a systemd mount unit, which directive specifies the location for mounting the chosen filesystem?
Where=
Location=
List=
Dest=
A: A. The Where= directive specifies the location for the final mounted filesystem.

Q: Which of the following commands can be used to format a FAT filesystem?
mkfs.fat
mkfs -f
mkfs --fat
mkfat
A: A. The mkfs.fat or mkfs.vfat commands are valid for creation of FAT filesystems. There is no -f option to mkfs, and there is no mkfat command.

Q: Which of the following commands adds a journal to an existing ext2 filesystem?
tune2fs -jrn
e2fs -x
tune3fs
tune2fs -j
A: D. The tune2fs command is used for working with ext2, ext3, and ext4 filesystems. The -j option adds a journal. The other commands are not valid.

Q: Which of the following commands creates a snapshot of a btrfs subvolume?
btrfs subvolume snapshot
btrfs snapshot --create
btrfs create snapshot
btrfs --create
A: A. The snapshot subcommand of btrfs subvolume creates a snapshot. The other commands shown are not valid.

Q: Which option to xfs_repair will force log zeroing even if there may be metadata within the log?
-L
-v
-d
-V
A: A. The -L option forces the log to be cleared or zeroed out, which may cause a loss of data. The -v option sets verbose output; -V prints the version. The -d option performs a dangerous repair, which can be used on a read-only filesystem.

Q: Which of the following commands mounts a filesystem in read-only mode?
mount read-only
mount --read
mount -o ro
mount -or
A: C. The -o option enables the setting of one or more options for the mount command, and ro is read-only. Note that the -r option will also mount as read-only. The other options shown are not valid.

Q: When you are using tune2fs to set an extended option such as stripe_width, which command-line option is needed to signify that an extended option follows?
-extend
-E
-e
-f
A: B. The -E option signals that an extended option follows, such as stripe_width. The -f option forces an operation but should not be necessary for this solution, and the -e option sets the behavior on error. There is no -extend option.

Q: Which utility is used for formatting GPT disks?
gdisk
gptdisk
gpdisk
pgdisk
A: A. The gdisk utility is the equivalent of fdisk for working with GPT partitions. Later versions of fdisk can also be used to manage GPT partitions.

Q: What is the maximum size of a partition on an MBR-formatted disk?
2TB
4TB
2MB
512TB
A: A. The maximum size for a partition on an MBR disk is 2 terabytes. GPT has largely replaced MBR on newer Linux systems.

Q: Which option to mkfs.ext4 can be used to prevent reservation of blocks for system or superuser use?
-r 0
-r 0b
-m 0
-m 0b
A: C. The -m option with 0 will format the partition with no reserved blocks for superuser or system use. The -r option sets the filesystem revision.

Q: What is the default time in seconds that xfs_fsr will use to reorganize a filesystem?
3600
7200
86400
5150
A: B. The default time for filesystem reorganization is two hours, or 7200 seconds.

Q: A user who is a member of the custom admins group is attempting to read the contents of a file but is not the owner of the file. Rather than granting sudo access to this file, what is another way to grant read access, assuming that the file is currently marked with 640 permissions? Note that you should choose the most appropriate answer to fulfill the need while minimizing additional privileges.
Grant root access to the user.
Run chmod 777 on the file.
Use chgrp to change group ownership to admins.
Use chown to change the ownership of the file to the individual user.
A: C. The file permissions are 640, meaning that the group owner can read the file. Therefore, changing group ownership should have the fewest side effects. Granting root access is not preferred, especially noting that the problem statement indicated that granting sudo wasn’t preferred. While using chown on the file to change the owner would also work, it’s likely to have additional side effects that could prevent the owner of the file from reading and writing, and there isn’t enough information in the problem for that. Finally, running chmod 777 is almost never the correct solution to any problem on Linux.

Q: Which option to lsblk shows empty devices?
-g
-a
-r
-y
A: B. The -a option shows all devices, even those that are empty. The -r option is for raw devices, and the other options do not exist.

Q: The /media/ mount point is used frequently for which types of devices?
Hard drives
SAN
NAS
USB devices
A: D. USB devices and others removable media can typically be found within the /media/ mount point.

Q: Which of the following commands is used to format an exFAT filesystem?
mkexfat
mkfat.ex
mkfs.exfat
mkfs2.exf
A: C. The mkfs-related commands are typically used for formatting filesystems on Linux. In this case, mkfs.exfat is the correct option for formatting exFAT filesystems.

Q: Which of the following commands is used for debugging an XFS-formatted filesystem?
debug_xfs
xfs_debug
xfs_db
debugxfs
A: C. The xfs_db command is used for debugging XFS-formatted filesystems.

Q: You’re working with an ext2 filesystem and you suspect the superblock is corrupted. Which option to e2fsck enables you to specify the location of an alternate superblock?
-B
-s
-b
-o
A: C. The -b option is used to specify an alternate superblock and helps in the scenario described, where the superblock has been damaged. The -B option specifies the block size. There is no –s or -o option for e2fsck.

Q: Which option to df shows the numerical output in larger size increments, like MB, GB, TB, and so on rather than in bytes?
-h
-m
-n
-s
A: A. The -h option is the flag for human-readable formatting and shows numerical output in larger size increments rather than bytes. The other options are not valid for df.

Q: Assuming the use of Bash for the shell, in which file can the umask be set such that the file creation mask is set automatically on login?
/etc/umask.def
/etc/profile
/etc/bash.d/umask
/etc/bash.umask
A: B. The /etc/profile file is one of a few locations in which default options can be set for users of Bash. The other file locations shown do not exist.

Q: You need to enable two users to edit the same file but keep their own individual changes. Another administrator suggested making a symbolic link for the file. Is a symbolic link the appropriate solution for this scenario and, if not, what is?
A symbolic link is not appropriate because the users cannot keep their own changes. A copy would be a better option.
A symbolic link is appropriate here because each user can access the file, assuming write permissions.
A symbolic link is not appropriate given that the users will not have permissions on symbolic links. Linux cannot meet the scenario described.
A symbolic link is appropriate because symbolic links have the ability to do version control, thus enabling the scenario.
A: A. A symbolic link will not work. The users would be editing the same file and, without saving as a different filename, would not be able to keep their own edits.

Q: You have deleted a user from the system and want to determine if this user still has files on the system. Which command will fulfill this scenario?
locate <user>
find -uid <uid>
find -user <user>
fileloc -user <user>
A: B. The find command will be used for this purpose, and the -uid option will need to be used because the user has already been deleted. If the user had not been deleted, then the -user option would still work.

Q: You need to update the locate database. Which of the following commands is used for this purpose?
updatedb
locatedb
updlocdb
locdbupd
A: A. The updatedb command is used to update the locate database. The other commands are not valid.

Q: Which option to lsblk shows the UUID of each filesystem?
–u
-f
-o
-a
A: B. The -f option shows the UUIDs of the filesystems mounted on the system. The -a option shows all devices, the -o option enables specification of output columns, and the -u option does not exist.

Q: Which option to mkswap checks the device for bad blocks before formatting?
-b
-B
-c
-d
A: C. The -c option checks for bad blocks before formatting. The other options are not valid with mkswap.

Q: You are examining output from ls -la and one file contains the permissions -rwSrw-r--. To what does the S refer?
Specific execute
Source formatting
Selective execution
Sticky bit
A: D. The sticky bit has been set on the file as denoted by an uppercase S.

Q: You need to change file permissions to be setgid for a file called sync.sh. The file is normally permission 755. Which of the following commands accomplishes this task?
chmod 2775 sync.sh
chmod u+s sync.sh
chmod 2755 sync.sh
chmod 4755 sync.sh
A: C. Using octal form, 4 is user, 2 is group, and 1 is sticky bit. Therefore, 2755 would have setgid for the file.

Q: Which of the following commands finds files with a .sql extension across the entire filesystem?
find . -name "*.sql"
find /root -ext sql
find / -name "*.sql"
find / -exten ".sql"
A: C. The -name option is used for this purpose, and / indicates the root of the system. A * wildcard is used to indicate all filenames ending in .sql, as described in the scenario.

Q: When working with /etc/fstab to mount by UUID, which syntax is correct as the first column in /etc/fstab, assuming a UUID denoted by <UUID>?
<UUID>
UUID=<UUID>
ID=<UUID>
GPT=<UUID>
A: B. The UUID=<UUID> syntax is correct for the /etc/fstab file.

Q: Which option to du displays information on inode usage?
-i
-h
--inodes
-d
A: C. The --inodes option shows inode usage with du. The -h option is human-readable, and -d sets the maximum depth. There is no -i option for du.

Q: Which of the following find commands will look for files that are over 1GB in size?
find -size +1G
find -size 1GB
find -fssize +1GB
find -filesize +1G
A: A. The -size option is used with find for this purpose, and the +1G argument will look for files greater than 1 gigabyte. Note that if the + is omitted, only files of the exact size are found.

Q: You have a set of libraries that were installed into /usr/local/lib and would like to ensure that the libraries are also available in /usr/lib. What is the preferred way to make the libraries available in this location?
Copy the libraries.
Create a symbolic link.
Move the libraries.
Create a script to synchronize the libraries between the two locations with rsync.
A: B. A symbolic link is the preferred method because it does not require additional maintenance that a script would or that copying would in order to keep the libraries current. Moving the libraries may have unintended consequences if another program is dependent on the libraries in that location.