ITN 170 Midterm
Which prompt do regular users receive when logged in to the system? a. $ b. @ c. # d. !
a. $
A directory is a type of file. a. True b. False
a. True
Using a regular expression, how can you indicate a character that is not an a or b or c or d? a. [^abcd] b. not [a-d] c. [!a-d] d. !a-d
a. [^abcd]
A symbolic link is depicted by an @ symbol appearing at the beginning of the filename when viewed using the ls -l command. a. True b. False
b. False
Linux commands entered via the command line are not case sensitive. a. True b. False
b. False
Which of the following are characteristics of OSS? (Choose all that apply.) a. The value of the software is directly related to its price. b. The software is developed collaboratively. c. The source code for software is available for a small fee. d. Bugs are fixed quickly.
b. The software is developed collaboratively d. Bugs are fixed quickly
You want to see the filesystems that are in use on the system. What command could you use? (Choose all that apply.) a. cat /etc/fstab b. df -hT c. cat /etc/mtab d. ls /sys/block
b. df -hf c. cat /etc/mtab
After typing the command umask 731, the permissions on all subsequently created files and directories will be affected. In this case, what will be the permissions on all new files? a. rw-rw-rw- b. rwxrw-r-- c. ---r--rw- d. ----wx--x
c. ---r--rw-
What was created to define a standard directory structure and common file location for UNIX and Linux systems? a. POSIX b. X.500 c. FHS d. OOBLA
c. FHS
What will the following wildcard expression return: file[a-c]? a. filea-c b. filea, filec c. filea, fileb, filec d. fileabc
c. filea, fileb, filec
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? a. /dev/sda1 b. /dev/sda2 c. /dev/sdb1 d. /dev/sdc1
d. /dev/sdc1
Which of the following are common methods for gaining support for Linux? a. websites b. Linux User Groups c. online forums d. all these methods
d. All of these methods
How can you specify a text pattern that must be at the beginning of a line of text using a regular expression? a. Precede the string with a /. b. Follow the string with a \. c. Precede the string with a $. d. Precede the string with a ^.
d. Precede the string with a ^.
How can a user switch from insert mode to command mode when using the vi editor? a. Press the Ctrl+Alt+Del keys simultaneously. b. Press the Del key. c. Type a : character. d. Press the Esc key.
d. Press the Esc key.
The root user utilizes the chown command to give ownership of a file to another user. What must the root user do to regain ownership of the file? a. Have the new owner run chgrp and list the root user as the new owner. b. Run chgrp again listing the root user as the new owner. c. Nothing, because this is a one-way, one-time action. d. Run chown and list the root user as the new owner.
d. Run chown and list the root user as the new owner
Which command blanks the terminal screen, erasing previously displayed output? a. erase b. clean c. blank d. clear
d. clear
Which command can be used to repair an XFS filesystem? a. fsck -t xfs /dev/sdb1 b. e2fsck /dev/sdb1 c. fsck.xfs /dev/sdb1 d. xfs_repair /dev/sdb1
d. xfs_repair /dev/sdb1
When Linux is hosted within a container on a cloud provider, what cloud delivery model is being used? a. IaaS b. PaaS c. XaaS d. SaaS
b. PaaS
How can you protect a metacharacter (such as the $ character) from shell interpretation? a. Precede it with a /. b. Precede it with a \. c. Precede it with a $. d. It cannot be done because metacharacters are essential.
b. Precede it with a \.
Who formed the Free Software Foundation to promote open development? a. Dennis Ritchie b. Richard Stallman c. Linus Torvalds d. Ken Thompson
b. Richard Stallman
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
What does the /var directory contain? a. various additional programs b. log files and spool directories c. temporary files d. files that are architecture-independent
b. log files and spool directories
Which command mounts all existing filesystems in /etc/fstab? a. mount -f b. mount -a c. mount /etc/fstab d. mount /etc/mtab
b. mount -a
Which prompt does the root user receive when logged in to the system? a. $ b. @ c. # d. !
c. #
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.) a. Mount the two SSDs so they are accessible by the operating system. b. Mount a filesystem to each of the SSDs. c. Create one or more partitions on each of the SSDs. d. Use the vi editor to edit /etc/mtab and create an entry for 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.
c. 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
Which of the following is not a piece of information that the Fedora installation program prompts you for? a. time zone b. installation destination c. firewall settings d. installation language
c. Firewall settings
To which license does Linux adhere? a. BSD b. MIT c. GNU GPL d. Apache
c. GNU GPL
Which of the following Linux distributions is likely to be used by a cybersecurity worker? a. Fedora b. Ubuntu c. Kali d. Gentoo
c. Kali
When the core components of the Linux operating system are packaged together with other OSS, it is called a _____. a. new kernel b. new platform c. Linux distribution d. GNU Project
c. Linux distribution
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.
Which of the following is not an example of virtualization software that can be used to install Linux within another operating system? a. Oracle VirtualBox b. Microsoft Hyper-V c. Spiceworks d. UTM
c. Spiceworks
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? a. Nothing; the files are lost and cannot ever be accessed. b. Nothing; the files could not have been there because you can only mount to empty directories. c. Unmount the device from the directory. d. Run the fsck command to recover the files. e. Look in the lost+found directory for the files.
c. Unmount the device from the directory
Which of the following statements regarding LVM structure is correct? a. PVs are collections of VGs. b. LVs are created from the free space available within PVs. c. VGs are comprised of one or more PVs. d. PVs use the space within LVs to create VGs.
c. VGs are compromised of one or more PVs
A user typed the command pwd and saw the output: /home/jim/sales/pending. How could that user navigate to the /home/jim directory? a. cd .. b. cd /jim c. cd ../.. d. cd ./.
cd ../..
What is the default shell on most Linux systems called? a. SH b. BSH c. CSH d. BASH
d. BASH
Which three partitions are typically created at minimum during a Fedora Workstation Linux installation on a system with a UEFI BIOS? (Choose three answers.) a. / b. /boot c. swap d. /boot/efi
a. / b. /boot d. boot/efi
Which of the following kernels are development kernels? (Choose all that apply.) a. 2.3.4 b. 4.5.5 c. 5.10-rc5 d. 6.0.0
a. 2.3.4 c. 5.10-rc5
Which of the following is an absolute pathname? (Choose all that apply.) a. C:\myfolder\resume b. resume c. /home/resume d. C:home/resume
a. C:\myfolder\resume c. /home/resume
When sitting at a computer running Linux, what key combination do you press to switch to a graphical login screen? a. Ctrl+Alt+F1 b. Ctrl+Alt+F4 c. Ctrl+Alt+F2 d. Ctrl+Alt+F7
a. Ctrl+Alt+F1
Which two people are credited with creating the UNIX operating system? (Choose two answers.) a. Dennis Ritchie b. Richard Stallman c. Linus Torvalds d. Ken Thompson
a. Dennis Ritchie d. Ken Thompson
Which common desktop environments are available in most Linux distributions? (Choose all that apply.) a. GNOME b. CDE c. KDE d. RPM
a. GNOME c. KDE
On which types of systems can Linux be installed? (Choose all that apply.) a. IoT devices b. supercomputers c. servers d. workstations
a. IoT devices b. supercomputers c. servers d. workstations
What does the mv command do? (Choose all that apply.) a. It renames a file. b. It renames a directory. c. It moves a directory to another location on the filesystem. d. It moves a file to another location on the filesystem.
a. It renames a file. b. It renames a directory. c. It moves a directory to another location on the filesystem. d. It moves a file to another location on the filesystem.
What must a Fedora Linux user do to run cp or mv interactively and be asked whether to overwrite an existing file? a. Just run cp or mv because they run in interactive mode by default. b. Run interactive cp or interactive mv. c. Run cp -i or mv -i. d. Run cp -interactive or mv -interactive.
a. Just run cp or mv because they run in interactive mode by default
Linux was developed by _____ to resemble the _____ operating system. a. Linus Torvalds, MINIX b. Linus Torvalds, GNU c. Richard Stallman, GNU d. Richard Stallman, MINIX
a. Linus Torvalds, MINIX
What are some good reasons for using Linux in a corporate environment? (Choose all that apply.) a. Linux software is unlikely to be abandoned by its developers. b. Linux is secure and has a lower total cost of ownership than other operating systems. c. Linux is widely available for many hardware platforms and supports many programming languages. d. Most Linux software is closed source.
a. Linux software is unlikely to be abandoned by its developers b. Linux is secure and has a lower total cost of ownership than other operating systems c. Linux is widely available for many hardware platforms and supports many programming languages
Many types of software are available today. Which type of software does Linux represent? a. open source b. closed source c. freeware d. shareware
a. Open source
Hard links need to reside on the same filesystem, whereas symbolic links need not be on the same filesystem as their target. a. True b. False
a. True
Linux has only one root directory per directory tree. a. True b. False
a. True
The lvextend command can be used to add unused space within a volume group to an existing logical volume. a. True b. False
a. True
To install Linux within a virtual machine, you can specify the path to an ISO image that contains the Linux installation media within virtualization software without having to first write the ISO image to a DVD or USB flash drive. a. True b. False
a. True
After typing the ls -F command, you see the following line in the output: -rw-r-xr-- 1 user1 root 0 Apr 29 15:40 file1 How do you interpret the mode of file1? a. User1 has read and write, members of the root group have read and execute, and all others have read permissions to the file. b. Members of the root group have read and write, user1 has read and execute, and all others have read permissions to the file. c. All users have read and write, members of the root group have read and execute, and user1 has read permissions to the file. d. User1 has read and write, all others have read and execute, and members of the root group have read permissions to the file.
a. User1 has read and write, members of the root group have read and execute, and all others have read permissions to the file.
A file has the following permissions: r----x-w-. The command chmod 143 file1 would have the same effect as the command _____. (Choose all that apply.) a. chmod u+x-r,g+r-x,o+x file1 b. chmod u=w,g=rw,o=rx file1 c. chmod u-r-w,g+r-w,o+r-x file1 d. chmod u=x,g=r,o=wx file1 e. chmod u+w,g+r-w,o+r-x file1
a. chmod u+x-r, g+r-x, o+x file 1 d. chmod u=x, g=r-w, o+r-x file1
Which of the following commands will change the user ownership and group ownership of file1 to user1 and root, respectively? a. chown user1:root file1 b. chown user1 : root file1 c. chown root:user1 file1 d. chown root : user1 file1
a. chown user1:root file1
The vi editor can function in which two of the following modes? (Choose both that apply.) a. command b. input c. interactive d. insert
a. command d. insert
The tac command _____. a. displays the contents of a file in reverse order, last line first and first line last b. displays the contents of hidden files c. displays the contents of a file in reverse order, last word on the line first and first word on the line last d. is not a valid Linux command
a. displays the contents of a file in reverse order, last line first and first line last
Which command is used to format a partition on a hard disk drive with the ext4 filesystem? a. e2mkfs -t ext4 device b. makeext4FS device c. format_ext4 device d. ext4mkfs device
a. e2mkfs -t ext4 device
Which of the following commands can only be used to create partitions on a GPT storage device? a. gdisk b. cfdisk c. fdisk d. parted
a. gdisk
You know a Linux command will perform a desired function for you, but you cannot remember the full name of the command. You do remember it will flush a variable from your system. Which command typed at a command prompt displays a list of commands that would likely contain the command you desire? a. man -k flush b. man -k find all c. man flush d. man -key flush
a. man -k flush
Which of the following are factors that determine which Linux distribution a user will use? (Choose all that apply.) a. package manager support b. hardware platform c. kernel features d. language support
a. package manager support b. hardware platform c. kernel features
Which culture embraced the term "GNU" (GNU's Not UNIX) and laid the free software groundwork for Linux? a. the hacker culture b. the BSD culture c. the cracker culture d. the artificial intelligence culture
a. the hacker culture
Which of the following components comprise an operating system? (Choose all that apply.) a. user interface b. kernel c. device drivers d. services
a. user interface b. kernel c. device drivers d. services
The command chmod 317 file1 would produce which of the following lines in the ls command? a. --w-r--rwx 1 user1 root 0 Apr 29 15:40 file1 b. --wx--xrwx 1 user1 root 0 Apr 29 15:40 file1 c. -rwxrw-r-x 1 user1 root 0 Apr 29 15:40 file1 d. --w-rw-r-e 1 user1 root 0 Apr 29 15:40 file1
b. --wx--xrwx 1 user1 root 0 Apr 29 15:40 file1
What is a common open source web server available for Linux? a. Samba b. Apache c. Squid d. NFS
b. Apache
When applied to a directory, the SGID special permission _____. a. allows users the ability to use more than two groups for files that they create within the directory b. causes all new files created in the directory to have the same group membership as the directory, and not the entity that created them c. causes users to have their permissions checked before they are allowed to access files in the directory d. cannot be used because it is applied only to files
b. Causes all new files created in the directory to have the same group membership as the directory, and not the entity that created them
What does the command df -i do? a. displays mounted filesystems using human-readable size formats b. displays the number of used and available inodes on each mounted filesystem c. displays mounted filesystems interactively, line by line d. nothing; it is not a valid command
b. Displays the number of used and available inodes on 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. a. True b. False
b. False
Character devices typically transfer data more quickly than block devices. a. True b. False
b. False
If you boot your computer from Linux live media, you will be able to use a fully functional Linux system prior to installing Linux on permanent storage. a. True b. False
b. False
Only the root user can modify a file that has the immutable attribute set. a. True b. False
b. False
The less command offers less functionality than the more command. a. True b. False
b. False
There is no real difference between the "S" and "s" special permissions when displayed using the ls -l command. One just means it is on a file, and the other means that it is on a directory. a. True b. False
b. False
Users enter commands directly to the kernel of the Linux operating system. a. True b. False
b. False
A special device file is used to _____. a. enable proprietary custom-built devices to work with Linux b. represent hardware devices c. keep a list of device settings specific to each individual user d. do nothing in Linux
b. represent hardware devices
After you log in to a terminal, you receive a user interface called a _____. a. GUID b. shell c. text box d. command screen
b. shell
Which command searches for and displays any text contents of a binary file? a. text b. strings c. od d. less
b. strings
When you change the data in a file that is hard-linked to three others, _____. a. the data in the file you modified and the data in all hard-linked files are modified because they have different inodes b. the data in the file you modified as well as the data in all hard-linked files are modified because they share the same data and inode c. only the data in the file you modified is affected d. only the data in the file you modified and any hard-linked files in the same directory are affected
b. the data in the file you modified as well as the data in all hard-linked files are modified because they share the same data and inode
A user types the command head /poems/mary. What will be displayed on the terminal screen? a. the first line of the file mary b. the first 10 lines of the file mary c. the header for the file mary d. the first 20 lines of the file mary
b. the first 10 lines of the file mary
Which command displays the users who are currently logged in to the Linux system? a. finger b. who c. id d. date
b. who
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 a. none, as fsck must be run manually for each filesystem b. /, swap, and /var c. /, /boot, and /home d. all of them, as fsck is run automatically at boot for all filesystems
c. /,/boot, and /home
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. Look in the root of the filesystem. b. The system prompts the user for a target location when it comes across a file it cannot repair. c. Mount the filesystem and check the lost+found directory underneath the mount point. d. View the contents of the directory /lost+found.
c. Mount the filesystem and check the lost+found directory underneath the mount point
What must you do to successfully run the fsck command on a filesystem? a. Run the fsck command with the -u option to automatically unmount the filesystem first. b. Choose yes when warned that running fsck on a mounted filesystem can cause damage. c. Unmount the filesystem. d. Ensure that the filesystem is mounted.
c. Unmount the filesystem
What command is equivalent to the man -k keyword command? a. find keyword b. man keyword c. apropos keyword d. appaloosa keyword
c. apropos keyword
If a user's current directory is /home/mary/project1, which command could they use to move to the etc directory directly under the root? a. cd .. b. cd etc c. cd /etc d. cd \etc
c. cd /etc
Which of the following components is required to run Linux virtual machines? a. container runtime b. desktop environment c. hypervisor d. orchestration software
c. hypervisor
After typing the ls -a command, you notice a file whose filename begins with a period (.). What does this mean? a. It is a binary file. b. It is a system file. c. It is a file in the current directory. d. It is a hidden file.
c. it is a hidden file.
If "resume" is the name of a file in the home directory off the root of the filesystem and your present working directory is home, what is the relative name for the file named resume? a. /home/resume b. /resume c. resume d. \home\resume
c. resume
Given the following output from the ls command, how many other files are hard linked with file3?drwxr-xr-x 3 root root 4096 Apr 8 07:12 Desktop -rw-r--r-- 3 root root 282 Apr 29 22:06 file1 -rw-r--r-- 1 root root 282 Apr 29 22:06 file2 -rw-r--r-- 4 root root 282 Apr 29 22:06 file3 -rw-r--r-- 2 root root 282 Apr 29 22:06 file4 -rw-r--r-- 1 root root 282 Apr 29 22:06 file5 -rw-r--r-- 1 user1 sys 282 Apr 29 22:06 file6 a. one b. two c. three d. four
c. three
You noticed a file in your home directory that has a + symbol appended to the mode. What does this indicate? a. Special permissions have been set on the file. b. The file has one or more files on the filesystem that are hard-linked to it. c. The sticky bit directory permission has been set on the file and will remain inactive as a result. d. Additional entries exist within the ACL of the file that can be viewed using the getfacl command.
d. Additional entries exist within the ACL of the file that can be viewed using the getfacl command.
What component within a CD workflow creates a new virtual machine or container to host the web app? a. orchestration server b. testing server c. code repository server d. build automation server
d. Build automation server
What does the du -hs /var command do? a. shows the users connected to the /var directory b. shows the size of all directories within the /var directory c. dumps the /var directory d. displays the total size of the /var directory
d. Displays the total size of the /var directory
After typing the ls -F command, you notice a filename that ends with an * (asterisk) character. What does this mean? a. It is a hidden file. b. It is a linked file. c. It is a special device file. d. It is an executable file.
d. It is an executable file.
Which command is used to display the amount of free space that exists on a filesystem? a. fsck b. quota c. du d. df
d. df
What command can you use to safely shut down the Linux system immediately? a. shutdown -c b. shutdown -r c. down d. halt
d. halt
What equivalent to the man command generally provides an easier-to-read description of the queried command and contains links to other related information? a. who b. man help c. man -descriptive d. info
d. info
Which command would a user type on the command line to find out the current directory in the directory tree? a. pd b. cd c. where d. pwd
d. pwd
What will typing q! at the : prompt in command mode do when using the vi editor? a. quit as no changes were made b. quit after saving any changes c. nothing because the ! is a metacharacter d. quit without saving any changes
d. quit without saving any changes
The default permissions given by the system prior to analyzing the umask are _____ for newly created directories and _____ for newly created files. a. rw-rw-rw- and rw-rw-rw- b. rw-rw-rw- and r--r--r-- c. rw-rw-rw- and rwxrwxrwx d. rwxrwxrwx and rw-rw-rw-
d. rwxrwxrwx and rw-rw-rw-
Which of the following refers to the third primary partition on the second SAS hard disk drive within Linux? a. hdb2 b. sda3 c. hdb3 d. sdb3
d. sdb3
The which command _____. a. can only be used to search for aliases b. searches for a file in all directories, starting from the root c. is not a valid Linux command d. searches for a file only in directories that are in the PATH variable
d. searches for a file only in directories that are in the PATH variable