CIT 352 Operating Systems Exam 2 Study Guide

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

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 -T c. cat /etc/mtab d. ls /sys/block

b. df -T c. cat /etc/mtab

What does the command dumpe2fs -h do? a. backs up an ext2 filesystem b. displays the number of used and available inodes for an ext2/ext3/ext4 filesystem c. dumps an ext2 filesystem d. nothing; it is not a valid command

b. displays the number of used and available inodes for an ext2/ext3/ext4 filesystem

The current value for the HOME variable is displayed by which of the following commands? (Choose all that apply.) a. echo HOME= b. echo ~ c. echo $HOME d. echo ls HOME

b. echo ~ c. echo $HOME

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 kilobytes

b. has no data section c. displays a major and minor number in place of a file size

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

Where is Grub2 bootloader executable file located at on a Fedora Linux system with UEFI and GPT? a. /boot/grub2/grubx64.efi b. /etc/grub2/grubx64.efi c. /boot/efi/EFI/fedora/grubx64.efi d. /etc/efi/EFI/FEDORA/GRUBX64.EFI

c. /boot/efi/EFI/fedora/grubx64.efi

You want to view log files to get information about a problem that occurred during a Linux installation. In which directory will you likely find the log files? a. /root/log b. /sys/log c. /var/log d. /etc/log

c. /var/log

Jim 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 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.

What does the dmesg command do? a. Analyzes core dump files b. Delete log files c. Displays messages generated by device drivers d. Detaches message

c. Displays messages generated by device drivers

What component of a Linux server is used to connect to a Fibre Channel SAN? a. FC initiator b. FC target c. FC HBA d. WWPN

c. FC HBA

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.

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.

What type of redundant storage configuration is most common for hosting the operating system and applications on a server? a. RAID 5 b. ZFS c. RAID 1 d. SAN + DM-MPIO

c. RAID 1

A user mounts a device to a mount point directory and realizes afterward she needs 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 file. e. Look in the lost+found directory for the file.

c. Unmount the device from the directory.

Before a user-defined variable can be used by processes that run in subshells, that variable must be __________. a. imported b. Falsevalidated by running the env command c. exported d. redirected to the BASH shell

c. exported

Which command is used to update the grub.cfg file? a. grub2-config -o /boot/grub2/grub.cfg b. grub2-configmk -o /boot/grub2/grub.cfg c. grub2-mkconfig -o /boot/grub2/grub.cfg d. grub2-setconfig -o /boot/grub2/grub.cfg

c. grub2-mkconfig -o /boot/grub2/grub.cfg

Which of the following describes a computer that is used to access an iSCSI hard disk across the network? a. iSCSI target b. iSCSI requestor c. iSCSI initiator d. iSCSI terminator

c. iSCSI initiator

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 does the du -s /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

Which command do you use to display the total disk space consumed under /home/user1? a. du /home/user1 b. du -T /home/user1 c. du -h /home/user1 d. du -s /home/user1

d. du -s /home/user1

Every if construct begins with if and must be terminated with _________. a. end b. endif c. stop d. fi

d. fi

Which of the following commands can be used on a modern Linux system to view hardware information that was captured at the beginning of the boot process? a. less /var/log/boot.log b. less /var/log/messages c. less /var/log/syslog d. journalctl -k

d. journalctl -k

Which of the following is not a type of RAID? a. hardware RAID b. software RAID c. firmware RAID d. serial RAID

d. serial RAID

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

After a partition on a hard disk is formatted with a filesystem, all partitions on that hard disk drive must use the same filesystem. True or False?

False

BTRFS filesystems do not need to be checked for errors as they are resilient to data corruption. True or False?

False

Because stderr and stdout represent the results of a command and stdin represents the input required for a command, only stderr and stdout can be redirected to/from a file. True or False?

False

Character devices typically transfer data more quickly than block devices. True or False?

False

Today, web, mail, print, and other services are run on physically separate enterprise servers. True of False?

False

You can mount/unmount a device even if a user process is using the mount point. True of False?

False

Both aliases and functions can be used to store commands that can be executed, but functions can also accept positional parameters. True or False?

True

The lvextend command can be used to add unused space within a volume group to an existing logical volume. True or False?

True

The sed and awk commands are filter commands commonly used to format data within a pipe. True or False?

True

Which of the following RAID levels is not fault tolerant? a. RAID 0 b. RAID 1 c. RAID 4 d. RAID 5

a. RAID 0

How do you export a variable? (Choose all that apply) a. VAL="My val"; export VAL b. VAL="My val"; export $VAL c. export VAL="My val" d. export $VAL="My val"

a. VAL="My val"; export VAL c. export VAL="My val"

Which of the following will set VAL to 0? (Choose all that apply) a. VAL=0 b. VAL = 0 c. VAL="0" d. VAL = "0"

a. VAL=0 c. VAL="0"

How do you find out which filesystem the root partition uses? (Select two) a. df -T b. ls -l / c. cat /etc/fstab d. fstype

a. df -T c. cat /etc/fstab

Which of the following commands can only be used to create partitions on a GPT hard disk? a. gdisk b. cfdisk c. fdisk d. parted

a. gdisk

Where is the /proc filesystem stored? a. in RAM b. on the hard disk drive in the / directory c. on the hard disk drive in the /etc directory d. on the hard disk drive in the /var directory

a. in RAM

Which outputs are a result of the following command? (Select two) $ sed s/o/@/g < file1 a. R@bin Hood b. Blue M@@n c. Outstanding Outcome d. Oct@ber N@vember

b. Blue M@@n d. Oct@ber N@vember

Which one is NOT a component of LVM? a. Physical Volume b. Group Volume c. Volume Group d. Logical Volume

b. Group Volume

Which statements are true for LVM Logical Volume? (Select two) a. LV must be unmounted before it can be extended b. Multiple LVs can exist on a single VG c. Each LV maps to a PV d. Each LV can have a different filesystem

b. Multiple LVs can exist on a single VG d. Each LV can have a different filesystem

What do subdirectories whose names are numbers under /proc directory represent? a. Installed hardware b. Processes c. Lost+Found files d. Logs

b. Processes

BTRFS can detect and repair data errors automatically as data is read and written. True of False?

False

Due to advancements in computing technology, there is a thin line between high end business PCs and enterprise servers' hardware specifications. True of False?

False

ZFS volumes are mounted at boot time from entries within /etc/fstab by default. True of False?

False

ZFS volumes are mounted at boot time from entries within /etc/fstab by default. True or False?

False

Find the match. (Options) Halt Single User Mode Multiuser Mode Graphical Mode (Options) Server's default mode gdm No daemons The root user only

Halt - No daemons Single User Mode - The root user only Multiuser Mode - Server's default mode Graphical Mode - gdm

A for construct is a loop construct that processes a specified list of objects. As a result, it is executed as long as there are remaining objects to process. True or False?

True

BTRFS is currently being developed to become a replacement for ext4. True of False?

True

Before creating an LVM Physical Volume, you must create a standard partition. True or False?

True

DM-MPIO can be configured to provide multiple, redundant connections to data stored on a SAN. True or False?

True

Suppose file1 exists but dir1 does not. Which commands will write stdout and stderr to separate files? (Select two) a. $ cat file1 dir1 >file2 2>file3 b. $ cat file1 dir1 >file2 >file3 c. $ cat file1 dir1 >>file2 >>file3 d. $ cat file1 dir1 2>file3 1>file2

a. $ cat file1 dir1 >file2 2>file3 d. $ cat file1 dir1 2>file3 1>file2

Which commands will work? (Select two) a. $ ls > file1 b. $ file1 > file2 c. $ wc < file1 d. $ wc | file1

a. $ ls > file1 c. $ wc < file1

Which numeric variable test expressions work? (Select two) a. (($A == $B)) b. ((! $A -eq $D)) c. (($A != $C)) d. ((! $A = $D))

a. (($A == $B)) c. (($A != $C))

Which of the following files is always executed immediately after any user logs in to a Linux system and receives a BASH shell? a. /etc/profile b. ~/.bash_profile c. ~/.bash_login d. ~/.profile

a. /etc/profile

Linux servers are typically installed in a rack using rackmount server hardware. Which of the following describes the minimum height of a rackmount server? a. 1U b. Series A c. Type A d. Level 5

a. 1U

Which statements are true for LVM Volume Group? (Select two) a. A VG consists of one or more PVs b. PVs in a VG must be contiguous c. A VG can be extended d. A VG is formatted before its use

a. A VG consists of one or more PVs c. A VG can be extended

Which type of RAID can be entirely configured during the Linux installation process? a. hardware RAID b. software RAID c. firmware RAID d. serial RAID

b. software RAID

Which of the following variables could access the value "/etc" within the sample shell script, if the sample shell script was executed using the bash sample /var /etc /bin command? a. $0 b. $1 c. $2 d. $3

c. $2

Given the following output from /etc/fstab, which filesystems will be automatically checked on boot by the fsck command? /dev/sda1 / ext4 defaults 1 1 none /dev/pts devpts gid=5,mode=620 1 0 none /proc proc defaults 0 1 none /dev/shm tmpfs defaults 1 0 /dev/sdc2 swap swap defaults 0 1 /dev/dvd /media/dvd iso9660 noauto,ro 0 0 a. none, as fsck must be run manually for each filesystem b. /, /dev/pts, and /dev/shm c. /, /proc, and swap d. all of them, as fsck is run automatically at boot for all filesystems

c. /, /proc, and swap

What command do you use to check whether a module is installed? a. chckmod b. infomod c. lsmod d. testmod

c. lsmod

Which of the following operators reverses the meaning of a test statement? a. #! b. -o c. -a d. !

d. !

You plug a USB flash memory drive into a system that has two SATA hard disks. How will the partition on this USB flash memory drive be identified by Linux? a. /dev/sda1 b. /dev/sda2 c. /dev/sdb1 d. /dev/sdc1

d. /dev/sdc1

To which directory will the test ZFS volume from the previous question be mounted by the ZFS system? a. /mnt/test b. /media/test c. /zfs/test d. /test

d. /test

Reorder the steps to install a new disk drive on a Linux workstation. 1. Install a device driver if not present 2. Mount the device 3. Create a partition 4. Install a filesystem 5. Attach a physical device 6. Create a mount point if it doesn't exist a. 5, 6, 2, 4, 1, 3 b. 5, 6, 4, 2, 3, 1 c. 5, 1, 2, 6, 4, 3 d. 5, 1, 3, 6, 2, 4

d. 5, 1, 3, 6, 2, 4

Put them in the correct order for booting and initializing a Linux system. 1. Load init daemon 2. Load Linux kernel 3. Load other daemons 4. Load GRUB2 5. Run POST a. 5, 4, 3, 2, 1 b. 5, 2, 1, 4, 3 c. 5, 4, 2, 3, 1 d. 5, 4, 2, 1, 3

d. 5, 4, 2, 1, 3

When viewing the output of the lsmod command, you notice several modules that start with vmw. What does this indicate? a. Linux is running as a guest operating system. b. Device drivers need to be installed on your system. c. There is no virtual memory in your system. d. The system is running the KVM hypervisor.

a. Linux is running as a guest operating system.

Which of the following lines can be used to perform command substitution within a shell script? (Choose all that apply.) a. `command` b. ${command} c. ${!command} d. $(command)

a. `command` d. $(command)

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 comprised of one or more PVs

What would be the effect of using the alias command to make an alias for the date command named cat in honor of your favorite pet? a. It cannot be done as there already is an environment variable cat associated with the cat command. b. It cannot be done because there already is a command cat on the system. c. When you use the cat command at the command prompt with the intention of viewing a text file, the date appears instead. d. There is no effect until the alias is imported because it is a user-declared variable.

c. When you use the cat command at the command prompt with the intention of viewing a text file, the date appears instead.

You have redirected stderr to a file called Errors. You view the contents of this file afterward and notice that there are six error messages. After repeating the procedure, you notice that there are only two error messages in this file. Why? a. After you open the file and view the contents, the contents are lost. b. The system generated different stdout. c. You did not append the stderr to the Error file, and, as a result, it was overwritten when the command was run a second time. d. You must specify a new file each time you redirect because the system creates the specified file by default.

c. You did not append the stderr to the Error file, and, as a result, it was overwritten when the command was run a second time.

Which command can you use during a system rescue to switch from the root of the live OS to the root of the Linux system installed on the hard disk? a. mount b. sysimage c. chroot d. rescue

c. chroot

Which of the following commands can be used on a modern Linux system to view the same information show by the dmesg command? a. less /var/log/boot.log b. less /var/log/messages c. journalctl -b d. journalctl -k

d. journalctl -k

Which devices will be checked by fsck during the boot time? # cat /etc/fstab .... /dev/sda1 / ext4 defaults 1 1 /dev/sda2 /boot ext4 defaults 1 2 /dev/sda3 swap swap defaults 0 0 /dev/sdb1 /data ext4 defaults 1 1 a. /dev/sda1 and /dev/sda2 b. /dev/sda2 and /dev/sda3 c. /dev/sda3 and /dev/sdb1 d. None of the above

a. /dev/sda1 and /dev/sda2

What does export a variable mean? a. Allow the variable to become accessible by child processes b. Allow the variable to become accessible by parent process c. Send the variable to a file d. Send the variable to foreign countries

a. Allow the variable to become accessible by child processes

Which outputs are a result of the following command? (Choose all that apply) Assume each original name started with a capitalized letter followed by lower-case letters. $ tr [h-z][H-Z] < names a. DONaLd DUcK b. MIcKeY MOUSe c. WaLT DiSNey d. WiNNie THe POOH

a. DONaLd DUcK b. MIcKeY MOUSe

You attempt to perform the git commit -m "Added listdir function" but the command fails. What are possible reasons for the failure? (Choose all that apply.) a. The user performing the commit has not set their Git user information. b. No files were added to the Git index beforehand. c. The user performing the commit is not running the command from within the Git repo directory. d. The master branch was not specified within the command itself.

a. The user performing the commit has not set their Git user information. b. No files were added to the Git index beforehand. c. The user performing the commit is not running the command from within the Git repo directory.

Which of the following will display the message welcome home if the cd /home/user1 command is successfully executed? a. cd /home/user1 && echo "welcome home" b. cat "welcome home" || cd /home/user1 c. cd /home/user1 || cat "welcome home" d. echo "welcome home" && cd /home/user1

a. cd /home/user1 && echo "welcome home"

Which statement describes a device file? (Select three) a. mknod command will create it b. Does not have an associated data block c. Exists under /boot directory d. A file through which OS can read/write to the device through a device driver

a. mknod command will create it b. Does not have an associated data block d. A file through which OS can read/write to the device through a device driver

Which construct can be used in a shell script to read stdin and place it in a variable? a. read b. sum c. verify d. test

a. read

Consider the following shell script: echo -e "What is your favorite color?--> \c" read REPLY if [ "$REPLY" = "red" -o "$REPLY" = "blue" ] \ then echo "The answer is red or blue." else echo "The answer is not red nor blue." fi What would be displayed if a user executes this shell script and answers Blue when prompted? a. The answer is red or blue. b. The answer is not red nor blue. c. The code would cause an error. d. The answer is red or blue. The answer is not red nor blue.

b. The answer is not red nor blue.

Which command is used to format a partition on a hard disk drive with the ext4 filesystem? a. format_ext4 device b. ext4mkfs device c. e2mkfs -t ext4 device d. makeext4FS device

c. e2mkfs -t ext4 device

Which mode will the system be in? # init 3 a. Not used b. Single User Mode c. Multiuser Mode d. Extended Multiuser Mode

d. Extended Multiuser Mode

Which of the following could result in a segmentation fault (fatal signal 11) during a Fedora installation? a. RAM problems b. overclocked CPU c. faulty hardware components d. all of the above

d. all of the above

What is system rescue? a. The process of using a live OS to repair problems associated with the live OS. b. The process of using a live OS to repair problems on another Linux system installed on a separate disk. c. The process of using the installed tools on the current system to repair problems associated with the current system. d. The process of saving power on the current system.

b. The process of using a live OS to repair problems on another Linux system installed on a separate disk.

What is Git? a. Another name for Gigabit b. Version control software c. Configuration management software d. Open source malware

b. Version control software

What command can be used to create a ZFS volume called test from the space on /dev/sdb and /dev/sdc that functions like RAID level 1? a. zpool create test /dev/sdb /dev/sdc b. zpool create test mirror /dev/sdb /dev/sdc c. zpool create test raidz /dev/sdb /dev/sdc d. zpool create test raidz2 /dev/sdb /dev/sdc

b. zpool create test mirror /dev/sdb /dev/sdc

Which of the following commands can quickly determine whether your network hardware was detected properly following a Linux installation? a. cat /proc/modules/network b. lspci c. lshw -class network d. dmesg

c. lshw -class network

Which command is used to format a partition on a hard disk drive with the ext4 filesystem? a. format_ext4 device b. ext4mkfs device c. mke2fs -t ext4 device d. makeext4FS device

c. mke2fs -t ext4 device

Which window manager does GNOME version 3 use? a. kwin b. metacity c. mutter d. twm

c. mutter

Which command could you use to see a list of all environment and user-defined shell variables as well as their current values? a. ls /var b. env c. set d. echo

c. set

What does &> accomplish when entered on the command line after a command? a. It redirects both stderr and stdout to the same location. b. It does not accomplish anything. c. It redirects stderr and stdin to the same location. d. It appends stdout to a file.

a. It redirects both stderr and stdout to the same location.

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.

a. Run the fsck command with the -u option to automatically unmount the filesystem first.

Which command is used to manually start a daemon under systemd (systemd specific command)? a. start <service>.service b. service <service>.service status c. systemctl start <service>.service d. initctl restart <service>.service

c. systemctl start <service>.service

When configuring a virtual hard disk file, which term refers to the feature that allows the virtual hard disk file to expand dynamically as space is requested by the guest operating system? a. thick provisioning b. Type 1 c. thin provisioning d. Type 2

c. thin provisioning

How do you indicate a comment line in a shell script? a. There are no comment lines in a shell script. b. Begin the line with #!. c. Begin the line with !. d. Begin the line with #.

d. Begin the line with #.

Which line is incorrect for the if construct? A. if [ this is true ] B. then C. do these commands D. elseif [ this is true ] E. then F. do these commands G. fi a. A b. B c. C d. D e. E f. F g. G

d. D

Find the match. (Options) RAID 0 RAID 1 RAID 5 RAID 6 (Options) Withstand up to one disk loss Complete replica of another disk Withstand up to two disk losses Performance improvement but no protection

RAID 0 - Performance improvement but no protection RAID 1 - Complete replica of another disk RAID 5 - Withstand up to one disk loss RAID 6 - Withstand up to two disk losses

Find the match. (Options) Supported by Linux Most SAN implementation Implemented by BIOS (Options) Hardware RAID Software RAID Firmware RAID

Supported by Linux - Software RAID Most SAN implementation - Hardware RAID Implemented by BIOS - Firmware RAID


Set pelajaran terkait

Rolfs APUSH Period 1 and 2 Terms

View Set

PEDIA: ENDOCRINE/GHD/PKU/Diabetes/DKA

View Set

Nursing Management During the Postpartum Period

View Set

BIOL220 Transport: Water Potential

View Set