Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 22

Hardware

and Device Configuration


Questions

1. Which process types are supported by Red Hat Enterprise Linux?
a. Intel and AMD x86 32 bit processors
b. Intel and AMD x86 64 bit processors
c. IBM s/390 processors
d. IBM series Z processors
e. All of the above

2. The /proc filesystem provides what function?
a. It provides multiprocessing (SMP) support for the Linux kernel.
b. It provides support for larger than 4GB of memory installed in the system.
c. It provides space for memory swap (paging).
d. It provides an interface for humans to view information in the kernel.
e. None of the above

3. What is an expected device name for a USB drive on a system ?
a. /dev/hdb
b. /dev/ubb
c. /dev/sdb
d. /dev/usbb
e. None of the above

4. Which file contains a snapshot of the kernel's dmesg buffer soon after the most recent boot?
a. /var/log/messages
b. /var/log/boot.log
Hardware Overview
rha130-6.1-1 12 Copyright 2011, Red Hat Inc.
c. /var/log/dmesg
d. /var/log/klog
e. None of the above

5. Which command displays the current contents of the kernel's dmesg buffer?
a. klog
b. kmesg
c. kdump
d. dlog
e. None of the above

6. What command can be used to monitor hardware changed dynamically?
a. monitor -hw
b. lshw
c. watchhw
d. hwmonitor
e. lshal m

Use the following transcript to answer the next 4 questions.
[root@station root]$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 8
model name : Pentium III (Coppermine)
stepping : 3
cpu MHz : 797.435
cache size : 256 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr
sse
bogomips : 1592.52
[root@station root]$ cat /proc/meminfo
MemTotal: 255184 kB
MemFree: 52280 kB
Buffers: 24436 kB
Cached: 90608 kB
SwapCached: 6532 kB
...
SwapTotal: 521632 kB
SwapFree: 504940 kB
[root@station root]$ cat /proc/scsi/scsi
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
Hardware Overview
rha130-6.1-1 13 Copyright 2011, Red Hat Inc.
Vendor: ATA Model: ST9500325AS Rev: 0005
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi1 Channel: 00 Id: 00 Lun: 00
Vendor: hp Model: DVDRAM GT30L Rev: mP04
Type: CD-ROM ANSI SCSI revision: 05
Host: scsi4 Channel: 00 Id: 00 Lun: 00
Vendor: SanDisk Model: Cruzer Mini Rev: 0.2
Type: Direct-Access ANSI SCSI revision: 02

7. In general terms, what is the speed of the processor?
a. 800 megahertz
b. 256 megahertz
c. 1.6 gigahertz
d. Not enough information is provided.
e. None of the above

8. In general terms, how much memory is installed on the local machine?
a. 256 kilobytes
b. 128 megabytes
c. 256 megabytes
d. 512 megabytes
e. None of the above

9. How many USB disks are attached to the machine?
a. 0
b. 1
c. 2
d. 3
e. Not enough information is provided.

10. Who manufactured the CDROM drive?
a. ATA
b. SANDISK
c. Intel
d. HP
e. Not enough information is provided.





Questions
1. In what directory are kernel modules found?
a. /lib/modules/kernel-version/
b. /boot/modules/
c. /usr/share/kernel-version/modules/
d. /var/lib/modules/

2. What command is used to request the removal of a module?
a. depmod -x
Kernel and Kernel Modules
rha130-6.1-1 22 Copyright 2011, Red Hat Inc.
b. modules -r
c. modprobe -r
d. rm /proc/modules

An administrator attempts to remove a module by running the following command.

[root@station root]# modprobe -r cdrom
cdrom: Device or resource busy

3. Which of the following would be a conventionally named static kernel image?
a. /boot/image-2.6.32-8
b. /boot/zimage-2.6.32-8
c. /boot/vmlinux-2.6.32-8
d. /boot/vmlinuz-2.6.32-8
e. None of the above

4. Which of the following could be a reason that the module cannot be removed?
a. The module's usage count is greater than 0.
b. The module is depended on by another module which is in use.
c. Once a modules is inserted into the kernel, it cannot be removed.
d. A or B

5. What command is used to list all currently inserted kernel modules?
a. depmod -l
b. modules
c. lsmod
d. cat /proc/kmod

6. Which command can be used to request the insertion of a kernel module?
a. modules -i
b. modprobe
c. vmlinuz
d. linux m

7. What configuration file is examined whenever modprobe inserts a module?
a. /etc/modprobed/*.conf
b. /etc/sysconfig/modules
c. /boot/modules/modprobe.conf
d. /etc/modtab

8. Which file contains values for /proc/sys/ directory entries which are set automatically at
boottime?
a. /etc/sysctl.conf
b. /etc/proc.conf
c. /etc/sysconfig/proc
d. /etc/systab

9. After editing the file mentioned in the previous question, what command can be run to immediately
implement the changes?
a. procctl -s
b. kernelctl -i
c. setproc
d. sysctl p

10. Within the configuration file mentioned above, which of the following lines would correctly set
the value of /proc/sys/net/ipv4/ip_forward to 1?
a. proc.sys.net.ipv4.ip_forward = 1
b. net.ipv4.ip_forward = 1
c. ip_forward = 1
d. sys.net.ipv4.ip_forward = 1

Questions
1. Which of the following commands conveniently lists all connected PCI devices?
a. listpci
b. pcidump
c. dmesg
d. kudzu
e. lspci

Use the following transcript to answer the next 2 questions.
[root@station root]$ cat /proc/interrupts
CPU0
0: 29957960 XT-PIC timer
1: 78565 XT-PIC keyboard
2: 0 XT-PIC cascade
5: 75302119 XT-PIC eth0
8: 1 XT-PIC rtc
9: 0 XT-PIC Intel ICH 82801AA
PCI Devices
rha130-6.1-1 30 Copyright 2011, Red Hat Inc.
11: 198578 XT-PIC usb-uhci, eth1
14: 258317 XT-PIC ide0
15: 20398 XT-PIC ide1
NMI: 0
ERR: 0

2. About how long has the system been running (since the last boot)?
a. About 30,000 seconds (about 8 hours)
b. About 20,000 seconds (about 5 hours)
c. About 10,000 seconds (about 3 hours)
d. About 10 days
e. Not enough information is provided

3. What about the above output implies a misconfiguration of the machine?
a. There are no NMI interrupts reported.
b. Two device drivers are conflicting over IRQ 11.
c. No device drivers have claimed IRQ's 4-7.
d. Only one CPU has been identified.
e. None of these conditions necessarily imply problems.

4. Which of the following files lists currently claimed I/O ports?
a. /etc/ioports
b. /var/log/ioports
c. /etc/sysconfig/ioports
d. /var/state/ioports
e. /proc/ioports
5. Which of the following files lists the physical addresses of currently mapped memory (including
RAM and other devices)?
a. /proc/slabinfo
b. /proc/meminfo
c. /proc/iomem
d. /var/log/meminfo
e. /etc/meminfo

Use the following transcript to answer the next 3 questions.
[root@station root]$ lspci -v
...
00:1f.2 USB Controller: Intel Corp. 82801AA USB (rev 02) (prog-if 00 [UHCI])
PCI Devices
rha130-6.1-1 31 Copyright 2011, Red Hat Inc.
Subsystem: Intel Corp. 82801AA USB
Flags: bus master, medium devsel, latency 0, IRQ 11
I/O ports at 2440 [size=32]
00:1f.5 Multimedia audio controller: Intel Corp. 82801AA AC'97 Audio (rev 02)
Subsystem: Compaq Computer Corporation: Unknown device b1bf
Flags: bus master, medium devsel, latency 0, IRQ 9
I/O ports at 2000 [size=256]
I/O ports at 2400 [size=64]
01:00.0 VGA compatible controller: nVidia Corporation NV5M64 [RIVA TNT2 Model 64/Model
64 Pro] (rev 15) Subsystem: nVidia Corporation: Unknown device 0017
Flags: bus master, 66Mhz, medium devsel, latency 64, IRQ 10
Memory at 41000000 (32-bit, non-prefetchable) [size=16M]
Memory at 44000000 (32-bit, prefetchable) [size=32M]
Expansion ROM at <unassigned> [disabled] [size=64K]
Capabilities: [60] Power Management version 1
Capabilities: [44] AGP version 2.0
...
6. What IRQ is the USB controller using?
a. 32
b. 9
c. 10
d. 11
e. Not enough information is provided

7. What I/O port base address(es) is (are) being used by the sound card?
a. The device is not using any I/O ports
b. 41000000
c. 2440
d. 2000 and 2400
e. Not enough information is provided

8. How much of the video card's memory has been mapped into the system?
a. 16 megabytes
b. 32 megabytes
c. 48 megabytes
d. 41000000 bytes
e. 44000000 bytes

Use the following transcript to answer the next question.
[root@station root]$ cat /etc/modprobe.d/custom.conf
alias parport_lowlevel parport_pc
alias eth0 8139too
PCI Devices
rha130-6.1-1 32 Copyright 2011, Red Hat Inc.
alias snd-card-0 i810_audio
alias usb-controller usb-uhci







9. Which kernel module is the device driver for the network interface card associated with the
interface eth0?
a. Network interface device drivers are always compiled into the static kernel image.
b. usb-uhci
c. i810_audio
d. 8139too
e. Not enough information is provided.

10. file lists modules loaded on the system?
a. /proc/devices
b. /proc/modules/devices
c. /proc/hw
d. /proc/lsmod
e. /proc/hwdevices

Questions
1. What two types of filesystem device nodes exist in Linux?
a. character and block device nodes
b. major and minor device nodes
c. hard and soft device nodes
d. hot and cold device nodes
e. None of the above

Use the following transcript to answer the next 3 questions.
[root@station root]$ ls -l /dev/fd?
brw-rw---- 1 root floppy 2, 0 Jan 30 2003 /dev/fd0
brw-rw---- 1 root floppy 2, 1 Jan 30 2003 /dev/fd1
brw-rw---- 1 root floppy 2, 2 Jan 30 2003 /dev/fd2
brw-rw---- 1 root floppy 2, 3 Jan 30 2003 /dev/fd3
brw-rw---- 1 root floppy 2, 128 Jan 30 2003 /dev/fd4
brw-rw---- 1 root floppy 2, 129 Jan 30 2003 /dev/fd5
brw-rw---- 1 root floppy 2, 130 Jan 30 2003 /dev/fd6
brw-rw---- 1 root floppy 2, 131 Jan 30 2003 /dev/fd7

2. What is the length of the file /dev/fd4?
a. 2 bytes
b. 128 bytes
c. 128 kilobytes
d. 4 kilobytes
e. The question is meaningless, because /dev/fd4 is a device node.

3. What type of file is /dev/fd2?
a. symbolic link
Filesystem Device Nodes
rha130-6.1-1 40 Copyright 2011, Red Hat Inc.
b. character device node
c. block device node
d. directory
e. None of the above

4. What is the major number of the file /dev/fd7?
a. 7
b. 131
c. 2
d. Not enough information is provided
e. The question is meaningless, because /dev/fd7 is a symbolic link.


Use the following transcript to answer the next 3 questions.
[root@station root]$ ls -l /dev/tty?
crw--w---- 1 root root 4, 0 Jan 30 2003 /dev/tty0
crw--w---- 1 root tty 4, 1 Oct 28 02:55 /dev/tty1
crw------- 1 root root 4, 2 Oct 24 17:40 /dev/tty2
crw------- 1 root root 4, 3 Oct 24 17:44 /dev/tty3
crw------- 1 root root 4, 4 Oct 24 17:44 /dev/tty4
crw------- 1 root root 4, 5 Oct 24 17:44 /dev/tty5
crw------- 1 root root 4, 6 Oct 24 17:44 /dev/tty6
crw--w---- 1 root root 4, 7 Jan 30 2003 /dev/tty7
crw--w---- 1 root root 4, 8 Jan 30 2003 /dev/tty8
crw--w---- 1 root root 4, 9 Jan 30 2003 /dev/tty9

5. What type of file is the file /dev/tty8?
a. regular file
b. block device node
c. symbolic link
d. directory
e. none of the above

6. What is the major number of the file /dev/tty3?
a. 3
b. 1
c. 4
d. 8
e. None of the above

7. What users on the machine can cause text to be displayed on the first virtual console (/dev/
tty1)?
a. root and members of the group tty
b. root only
c. root and members of the group console
d. all users
e. not enough information is provided

8. Which of the following files is the device node for the CDROM drive?
a. /dev/cd
b. /dev/sr0
c. /proc/scsi/sr0
d. /proc/scsi/cdrom
e. None of the above

9. Which of the following is the device node for the SCSI disk with a SCSI ID of 3?
a. /dev/sd2
b. /dev/sdc
c. /proc/scsi/sdc
d. Not enough information is provided
e. None of the above

10. A USB drive is added to the system. What command must be run to create the device node?
a. modprobe /dev/usb
b. mknod /dev/usb
c. No command needs to be run. USB devices do not use separate device nodes
d. No command needs to be run. udev will create the device node automatically
e. No command can be run. All device nodes are created at installation.



Questions
1. What is the name of the utility which displays a dynamically updated list of processes currently
running on the machine, as well as CPU and memory utilization statistics?
a. top
b. monitor
c. vmstat
d. ps
e. None of the above

Use the following transcript to answer the next 2 questions.
[root@station root]$ uptime
05:06:00 up 3 days, 12:25, 2 users, load average: 0.89, 3.25, 8.87

2. Which of the following best describes the activity of the machine?
a. The machine has recently been active, but is currently inactive.
b. The machine has recently been inactive, but is currently active.
c. The machine has been and continues to be active.
d. The machine has been and continues to be inactive.
Performance Monitoring
rha130-6.1-1 47 Copyright 2011, Red Hat Inc.
e. None of the above

3. How long has passed since the machine was most recently booted?
a. 5 hours
b. 8.87 hours
c. 12 hours
d. 2 hours
e. 84 hours

Use the following top 5 lines from the top command to answer the next 4 questions.
top - 05:14:52 up 3 days, 12:34, 2 users, load average: 4.39, 1.40, 0.48
Tasks: 86 total, 79 sleeping, 7 running, 0 zombie, 0 stopped
Cpu(s): 20.0%us, 79.8%sy, 0.4%ni, 0.0%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 255184k total, 247244k used, 7940k free, 91620k buffers
Swap: 521632k total, 20756k used, 500876k free, 67012k cached

4. How much physical memory does the machine have?
a. 512 megabytes
b. 128 megabytes
c. 64 megabytes
d. 1024 megabytes
e. 256 megabytes

5. Which of the following best describes the type of activity on the machine?
a. The machine is predominantly running processes which involve a lot of numeric computation.
b. The machine is predominantly running processes which involve a lot input and output activity.
c. The machine is predominantly idle, without many processes running.
d. None of the above describe the machine's activity.

6. Roughly what percentage of the machine's physical memory is devoted to caching I/O operations?
a. 5%
b. 10%
c. 25%
d. 33%
e. 60%






7. Roughly how much physical memory is being devoted to processes, in megabytes?
a. 255 - 92 = 163
Performance Monitoring
rha130-6.1-1 48 Copyright 2011, Red Hat Inc.
b. 255 - 8 = 247
c. 255 - 67 = 188
d. 255 - 92 = 163
e. 255 - 8 - (92 + 67) = 88

8. What file contains information about current memory utilization?
a. /etc/memory
b. /proc/top
c. /var/log/mem
d. /proc/meminfo
e. None of the above

Use the following transcript to answer the next 2 questions.
top - 05:32:33 up 3 days, 12:52, 2 users, load average: 1.92, 1.87, 1.87
Tasks: 87 total, 82 sleeping, 5 running, 0 zombie, 0 stopped
Cpu(s): 99.0%us, 1.0%sy, 0.0%ni, 0.0%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 255184k total, 250332k used, 4852k free, 8560k buffers
Swap: 521632k total, 76584k used, 445048k free, 100384k cached

9. On average, how many processes have been running for the past few minutes?
a. 0
b. 2
c. 5
d. 87
e. Not enough information is provided

10. Which of the following best describes the type of activity on the local machine?
a. The machine is predominantly idle, without many processes running.
b. The machine is predominantly running processes which involve a lot input and output from
the filesystem.
c. The machine is predominantly running processes which involve a lot of numeric computation.
d. None of the above describe the machine's activity.







Linux
Filesystem Management
Questions
Use the output from the following command to answer the next question.
[root@station root]$ cat /proc/partitions
major minor #blocks name
ng use aveq
8 0 8891650 sda
8 1 136521 sda1
8 2 3502170 sda2
8 3 2096482 sda3
8 4 1 sda4
8 5 2096451 sda5

1. Which of the following best explains why the partition sda4 is listed in /proc/partitions
with only a size of 1?
a. The partition has been initialized with a filesystem, but the filesystem is not mounted.
b. The partition is being used as the extended partition, and therefore is not accessed directly.
c. The partition has been initialized as swap space, but there has not yet been a high demand
placed on physical memory.
d. The disk has not yet had a partition sda4 allocated.
e. None of the above

2. Which of the following partitions could be an extended partition?
a. /dev/sda7
b. /dev/sdb5
c. /dev/sdb4
d. /dev/sdc8
e. None of the above

3. Which of the following would be a logical partition?
a. /dev/sda3
b. /dev/sda5
c. /dev/sdb1
d. /dev/sdb4
e. None of the above

4. Which of the following commands would list all known partitions?
a. fdisk --dump
b. dumppart
c. fdisk -cul
d. fdisk --list
e. None of the above

5. Which of the following commands could be used to add the partition /dev/sda8?
a. fdisk -a /dev/sda8
b. fdisk -cu /dev/sda8
c. fdisk -l /dev/sda8
d. fdisk --add /dev/sda8
e. None of the above






Use the following transcript to answer the next 3 questions.
[root@station root]$ fdisk -cul /dev/sdb
Disk /dev/sdb: 10.7 GB, 10737418240 bytes
255 heads, 63 sectors/track, 1305 cylinders, total 20971520 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
Disk Recognition and Partitioning
rha130-6.1-1 20 Copyright 2011, Red Hat Inc.
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x2f2333e8
Device Boot Start End Blocks Id System
/dev/sdb1 2048 206847 102400 83 Linux
/dev/sdb2 206848 16984063 8388608 83 Linux
/dev/sdb3 16984064 18032639 524288 82 Linux swap / Solaris
/dev/sdb4 18032640 20129791 1048576 83 Linux

6. Assuming that the system Id's indicate the true use of the partitions, approximately how much
partition space is allocated to swap space?
a. 128 megabytes
b. 520 megabytes
c. 8.4 gigabytes
d. 5.5 megabytes
e. Not enough information is provided

7. Approximately how much space is left unallocated on the drive /dev/sdb?
a. 0
b. 420 megabytes
c. 8.4 gigabytes
d. 84 megabytes
e. Note enough information is provided

8. The administrator wants to use the space is left unallocated on the drive /dev/sdb. What options
are avaialble?
a. A new ext4 filesystem can be created with the remaining space
b. A new extended partition can be created with the remaining space
c. One or more new logical partitions can be created with the remaining space
d. The remaining space is not available for use
e. Note enough information is provided

9. After editing the partition table with fdisk, what action must (usually) be taken for the kernel to
recognize the new partitions?
a. The machine must be rebooted.
b. The new partition should be added to /proc/partitions with a text editor.
c. The partprobe command should be run.
d. None of the above
e. Either A or C

10. Which of the following fdisk commands is used to abandon all changes?
a. a
b. q
c. x
d. w
e. z




Questions
1. Which of the following filesystems is usually associated with compact disks?
a. ext3
b. iso9660
c. reiserfs
d. vfat
e. None of the above

2. Which of the following commands could be used to create an ext3 filesystem?
a. mkfs.ext3
b. mkfs -t ext3
c. mke2fs -j
d. mkfs.ext2 -j
e. All of the above

3. Which of the following command lines could be used to create an ext2 filesystem with a blocksize
of 2048 bytes?
a. mke2fs -b 2048 /dev/sda4
b. mke2fs /dev/sda4
c. mke2fs -b2k /dev/sda4
d. mke2fs -b2 /dev/sda4
e. A and B

Use the following transcript to answer the next 2 questions.
[root@station root]# dumpe2fs /dev/sdb5
dumpe2fs 1.39 (29-May-2006)
Filesystem volume name: /home
Last mounted on: <not available>
Filesystem UUID: 4a26ac4a-fcd9-4231-bf3a-e5e5fb2456b5
Filesystem magic number: 0xEF53
Filesystem revision #: 1 (dynamic)
Filesystem features: has_journal filetype needs_recovery sparse_super
Default mount options: (none)
Filesystem state: clean
Errors behavior: Continue
Filesystem OS type: Linux
Inode count: 3842720
Block count: 7681070
Reserved block count: 384053
Free blocks: 1150544
Free inodes: 3597708
First block: 0
Block size: 4096
Fragment size: 4096
Blocks per group: 32768
Fragments per group: 32768
Inodes per group: 16352
Inode blocks per group: 511
Last mount time: Sun Oct 5 13:59:31 2003
Last write time: Sun Oct 5 13:59:31 2003
Mount count: 74
Maximum mount count: -1
Last checked: Fri Sep 19 09:16:20 2003
Check interval: 15552000 (6 months)
Next check after: Wed Mar 17 08:16:20 2004
Reserved blocks uid: 0 (user root)
Reserved blocks gid: 0 (group root)
First inode: 11
Inode size: 128
Journal UUID: <none>
Journal inode: 8
Journal device: 0x0000
First orphan inode: 0





4. Which of the following command lines could have created this filesystem? (Assume that the
filesystem has not been modified with tune2fs since it was created.)
a. mke2fs -L /home -b 2048 /dev/sdb5
b. mkfs.ext3 -b 2048 /dev/sdb5
c. mkfs -t ext2 -b 4096 /dev/sdb5
d. mke2fs -j -L /home -b 4096 -N 3842720 /dev/sdb5
e. None of the above

5. When creating this filesystem, which of the following would be the appropriate argument to the -i
command line switch to the mke2fs command to generate the appropriate number of inodes?
a. -i 2
b. -i 4096
c. -i 8192
d. -i 4
e. None of the above

6. When formatting a floppy with the mke2fs command, why might one be tempted to include the
-m 0 command line switch?
a. Because journaling would be too slow on a floppy, this command line switch would disable
journaling.
b. The command line switch would prevent any blocks being reserved for only the root user.
c. The command line switch would set the number of inodes to 0, which is appropriate for
temporary media such as floppies.
d. The command line switch would cause the floppy to be overwritten with binary 0's before the
filesystem is constructed, wiping clean any previous data.
e. None of the above

7. Which of the following command lines would create a filesystem with a volume label of data?
a. mkfse2 -l data /dev/sda1
b. mkfs.ext2 --label=data /dev/sda1
c. mkfs.ext2 -m data /dev/sda1
d. mkfs -t ext2 -L data /dev/sda1
e. None of the above

8. Which of the following command lines would create an ext4 filesystem with a block size of 4096?
a. mke2fs --journal --block=4096 /dev/sda1
b. mkfs.ext4 -b 4k /dev/sda1
c. mkfs -t ext2 -j -b4 /dev/sda1
d. mkfs -t ext4 --block=4k /dev/sda1
e. None of the above

9. Which of the following command line switches causes the mke2fs command to check the disk for
bad blocks before creating a filesystem?
a. -L
b. -c
c. -b
d. -s
e. None of the above

10. Your friend has just run the dumpe2fs command on his /home filesystem, and noticed that the
flag needs_recovery was set. What advice would you give him?
a. He should reboot his machine immediately.
b. When convenient, he should unmount the partition, and perform filesystem maintenance.
c. He should not be concerned, as the flag is always set on mounted filesystems.
d. He should not be concerned, as the Linux kernel automatically runs a filesystem recovery
algorithm every 10 minutes.
e. You do not believe him, and suspect he ran the dumpe2fs command on a partition that does
not contain an ext2 filesystem.

Questions
1. Which of the following could be a legitimate invocation of the mount command?
a. mount -t /dev/sda2 /home
b. mount /home /dev/sda2
c. mount /dev/sda2 /home
d. mount -o /home /dev/sda2
e. None of the above

2. Which of the following command lines would mount the device /dev/sda3, formatted with the
vfat filesystem, to the mount point /dosc?
a. mount -o vfat -d /dev/sda3 /dosc
b. mount -t vfat /dev/sda3 /dosc
c. mount -t vfat -o /dosc /dev/sda3
d. mount -o vfat /dosc /dev/sda3
e. None of the above

3. Which of the following is not a common Linux mount option?
a. mtime
b. noatime
c. noexec
d. ro
e. All are common mount options

Use the following transcript to answer the next 3 questions.
[root@station root]# mount
/dev/sda3 on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
/dev/sda1 on /boot type ext4 (rw)
tmpfs on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
[root@station root]# mount /dev/sda7 /var
[root@station root]# mount /dev/sda5 /var/www/html

4. Which partition contains the file /proc/meminfo?
a. /dev/sda1
b. /dev/sda7
c. /dev/sda5
d. /dev/sda3
e. None of the above

5. Which partition contains the mount point /var/www/html?
a. /dev/sda3
b. /dev/sda7
c. /dev/sda1
d. /dev/sda5
e. None of the above

6. When accessing the file /var/www/html/index.html, how many partitions does the kernel
involve?
a. 1
b. 3
c. 0
d. 2
e. Not enough information is provided



Use the following transcript to answer the next 2 questions.
[root@station root]# mount /dev/fd0 /mnt/floppy
[root@station root]# cd /mnt/floppy
[root@station floppy]# cal > september.txt
[root@station floppy]# umount /mnt/floppy
umount: /mnt/floppy: device is busy

7. Which is the most likely reason the /mnt/floppy device was considered busy?
a. The kernel had not yet finished writing the file september.txt.
b. Although the kernel had finished writing the file september.txt, the writes had not yet
been committed to disk.
c. The filesystem on the /mnt/floppy device has become corrupted.
d. The bash shell's current working directory is /mnt/floppy.
e. None of the above

8. Which of the following commands would resolve the problem, so that if it were immediately
followed by the same umount command listed above, the unmount would succeed?
a. fuser -m /mnt/floppy
b. fsck -m /mnt/floppy
c. sync
d. cd
e. None of the above

9. Which of the following command lines would add the noatime option to an already mounted /
home partition?
a. mount -o noatime /dev/sda4 /home
b. mount -a noatime /dev/sda4 /home
c. mount -remount -o noatime /dev/sda4 /home
d. mount -o remount,noatime /dev/sda4 /home
e. None of the above

Use the following transcript to answer the next question.
[root@station root]# mount
/dev/sdb6 on / type ext4 (rw)
none on /proc type proc (rw)
usbdevfs on /proc/bus/usb type usbdevfs (rw)
/dev/sdb7 on /var/ftp/pub type ext4 (rw)
/dev/sdb5 on /home type ext4 (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
none on /dev/shm type tmpfs (rw)

10. Which of the following command lines could be used to unmount the /home partition?
a. unmount /home
b. umount -t ext3
c. umount /dev/sdb5
d. unmount -a
e. None of the above

Questions
Use the following transcript to answer the next 5 questions.
[root@station root]# cat /etc/fstab
LABEL=/ / ext4 defaults 1 1
LABEL=/var/ftp/pub /var/ftp/pub ext4 defaults 1 2
LABEL=/home /home ext4 defaults 1 2
LABEL=/boot /mnt/boot ext4 defaults,noauto 1 2
/dev/sda5 /dos vfat defaults,noauto,user 0 2
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0
sysfs /sys sysfs defaults 0 0
tmpfs /dev/shm tmpfs defaults 0 0
LABEL=SWAP-sdb2 swap swap defaults 0 0
/dev/fd0 /media/floppy auto user 0 0
1. Which of the following mount points would not be used by a mount -a command?
a. /var/ftp/pub
b. /dev/pts
c. /home
d. /dos
e. All of the above mount points would be used.

2. Which of the following command lines would attempt to mount the /dev/sda5 partition?
a. mount /dev/sda5
b. mount /dos
c. mount /dev/sda5 /mnt/dos
d. All of the above
e. A and B only

3. Which of the following command lines would attempt to mount a filesystem to the /mnt/boot
directory?
a. mount -a
b. mount /boot
c. mount -L /boot
d. A and C
e. None of the above

4. What is the most likely reason that the third column of the last line contains the word auto?
a. Because a FAT or ext2 or otherwise formatted floppy could be inserted into the drive, the
filesystem type should be probed for each mount.
b. When a floppy is inserted into the drive, the filesystem should be automatically mounted.
c. Upon bootup, the system should attempt to mount the floppy automatically.
d. The auto filesystem is the most common filesystem used on floppy drives.
e. None of the above adequately explain the configuration.

5. What users would be able to mount the device /dev/fd0?
a. Only root may perform mounts.
b. Any user logged in physically at the console (and root).
c. Any user on the system.
d. The current owner of the directory /mnt/floppy (and root).
e. None of the above.

6. What does the noauto mount option imply?
a. The filesystem should not be managed by an automounting daemon.
b. The filesystem should not be automatically mounted whenever a file within the filsystem is
references.
c. The filesystem should not be mounted as part of the system startup process.
d. The line should not be automatically removed from the configuration file if the underlying
partition is deleted.
e. None of the above

7. What command could be used to create the label referred to by the LABEL= syntax in the /etc/
fstab file?
a. mke2fs
b. fdisk
c. mount
d. fuser
e. None of the above

Use the following transcript to answer the next 3 questions.
[root@station root]$ cat /etc/fstab
/dev/sda6 / ext4 defaults 1 1
/dev/sda2 /boot ext4 defaults 1 2
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0
sysfs /sys sysfs defaults 0 0
tmpfs /dev/shm tmpfs defaults 0 0
/dev/sda1 tmp ext4 defaults 1 2
/dev/sda3 /var ext4 defaults 1 2
/dev/sda4 /var/data ext4 defaults 1 1

8. What is suspicious about the first column of this file, which leads you to believe that there must
be some mistake?
a. A logical partition is being used as the root partition, which is not allowed.
b. A device of type "none" is being mounted to the /proc partition, which makes no sense.
c. All of the partitions are being mounted from a single drive.
d. There is a jump from 4 to 6 in the listed partitions, with no mention of partition number 5.
e. The file implies that all 4 primary partitions contain a filesystem, but a logical partition exists
as well.

9. What is suspicious about the second column of this file, which leads you to believe that there must
be some mistake?
a. Partitions are configured to be mounted to both /var/data and /var, but partitions may
only be mounted to directories contained by the root partition.
b. The mount point tmp is specified as a relative reference.
c. Filesystems are configured to be mounted to directories in the /dev directory, but the /dev
directory may only contain device nodes.
d. A partition is configured to be mounted to /, but only the kernel may mount the root partition.
e. A filesystem is configured to be mounted to /proc, but the kernel automatically mounts /
proc as part of its bootup process.

10. What is suspicious about the last column of this file, which leads you to believe that there must
be some mistake?
a. The column contains the value 0, when only the values greater than 0 are allowed.
b. The column contains multiple entries for the value "2", which will result in an error when the
fsck command tries to decide which to check first.
c. The column contains the value "2", when only the values 1 and 0 are meaningful.
d. The last column only exists for legacy reasons, so the fact that it contains non-zero values is
suspect.
e. The column contains multiple entries for the value "1", when the value 1 is only supposed to
be used for the root partition.

Questions
1. What is the threshold amount of physical memory, above which allocating swap space is no longer
recommended?
a. 128 megabytes
Managing Swap Space
rha130-6.1-1 59 Copyright 2011, Red Hat Inc.
b. 256 megabytes
c. 512 megabytes
d. 1 gigabyte
e. A swap partition should always be created, no matter how much physical memory is available.

2. Which of the following files lists currently active swap partitions?
a. /proc/swaps
b. /etc/fstab
c. /var/state/swap
d. /etc/swaptab
e. None of the above

3. Which file is used to define swap partitions which should be activated automatically as the system
boots?
a. /etc/swaptab
b. /etc/fstab
c. /proc/swaps
d. /var/state/swap
e. none of the above

4. What command line would be used to initialize a disk partition to be used as swap space?
a. swapinit /dev/sda3
b. mkswap /dev/sda3
c. mkfs -t swap /dev/sda3
d. fdisk /dev/sda3
e. None of the above

5. What command line would be used to initialize a file to be used as swap space?
a. mkswap /tmp/swapfile
b. mkswap -f /tmp/swapfile
c. swapinit -f /tmp/swapfile
d. mkswapfile /tmp/swapfile
e. None of the above

6. ext3 is to mount as swap is to ....
Managing Swap Space
rha130-6.1-1 60 Copyright 2011, Red Hat Inc.
a. swapon
b. mkswap
c. swaps
d. swapoff
e. startswap

7. Which of the following lines could be used to define a swap area that should be activated at system
startup in the /etc/fstab file?
a. /dev/sda4 swap swap defaults 0 0
b. swap /dev/sda4 swap defaults 0 0
c. /tmp/swapfile swap swap noauto 0 0
d. /tmp/swapfile none none defaults 0 0
e. None of the above

8. Which of the following commands is used to deactivate a swap area?
a. swapstop
b. umount
c. uswap
d. swapoff
e. None of the above

9. Which of the following command lines could be used to activate a swap partition with a priority
of 3?
a. mkswap -p 3 /dev/sda3; swapon /dev/sda3
b. swap /dev/sda3 3
c. mount -t swap -o pri=3 /dev/sda3
d. swapon -p 3 /dev/sda3
e. none of the above

10. Which of the following commands could confirm that a swap partition is active with a priority of 3?
a. cat /proc/swaps
b. cat /proc/meminfo
c. top
d. cat /proc/slabinfo
e. A and B
Questions
1. Which of the following command lines could be used to check and repair an ext2 filesystem?
a. fsck /dev/sda3
b. fsck -t ext2 /dev/sda3
c. fsck.ext2 /dev/sda3
d. e2fsck /dev/sda3
e. All of the above

2. Which of the following command lines could be used to assign the label /data to an ext2 filesystem?
a. e2label /data /dev/sda3
b. e2label -L /data /dev/sda3
c. e2label /dev/sda3 /data
d. label -t ext2 /dev/sda3 /data
e. None of the above

The remaining questions refer to the following scenario.
You have just attached a newly purchased drive to an already existing Red Hat Enterprise Linux
installation. Using only the tools discussed in this Workbook, you would like to create 6 ext4 filesystems,
each mounted to the directories /data1, /data2, ..., /data6, and a 256 megabyte swap partition.
You
would like all 6 partitions to be mounted and the swap area to be activated automatically at bootup.

3. Which of the following commands could you get away with not using?
a. e2label
b. mkswap
c. fdisk
d. mount
e. All of the above commands are required.

4. What is the most reasonable ordering for the commands you will use?
a. mke2fs, mkswap, fdisk, mount, swapon
b. fdisk, swapon, mkswap, mke2fs, mount
c. mount, fdisk, mke2fs, mkswap, swapon
d. fdisk, mke2fs, mkswap, mount, swapon
e. mkswap, swapon, mke2fs, mount, fdisk

5. At least how many logical partitions will need to be used?
a. 1
b. 2
c. 3
d. 4
e. 5

6. Which of the following command lines could be used to create an ext4 filesystem on the first logical
partition, and assign it the label /data3?
a. mkfs.ext4 -L /data3 /dev/sdd5
b. mkfs.ext4 /dev/sdd5; e2label /dev/sda5 /data3
c. mkfs.ext4 /dev/sdd5; tune2fs -L /dev/sda5 /data3
d. All of the above
e. None of the above

7. Once the ext4 filesystems have been created, and are all mounted, you decide that you would like
the filesystem on partition /dev/sdd2 to be an ext3 filesystem instead. Which command line could
be used to convert the filesystem to ext3 (without losing any data already in the filesystem)?
a. tune2fs -j /dev/sdd2
b. umount /dev/sdd2 && mkfs.ext3 /dev/sdd2
c. umount /dev/sdd2 && tune2fs -j /dev/sdd2
d. umount /dev/sdd2 && mke2fs -j /dev/sdd2
e. An ext4 filesystem cannot be reverted to an ext2 or ext3 filesystem

8. You decide that you would like to check and repair the filesystem on partition /dev/sdd3. You
unmount the partition. What command could you run next to perform the check?
a. swapoff /dev/sdd3
b. fsck.vfat /dev/sdd3
c. fisk /dev/sdd3
d. fsck /dev/sdd3
e. None of the above

9. The check and repair utility used above mentions that it has restored some file, but could not find
names for. Where should you look for these files?
a. The /lost+found directory in your root partition.
b. The lost+found directory in the repaired filesystem's root directory.
c. The /proc/lost+found directory.
d. The /tmp/lost+found directory.
e. None of the above

10. You realize that your previously installed Red Hat Enterprise Linux system had not used the
ext3 filesystem. After successfully converting your new ext2 filesystem to ext3, what additional
command should be run?
a. ext3init
b. kudzu
c. mkinitrd
d. setup
e. mkext3
Questions
1. Which of the following could be an appropriate reference to one of the volume group vg0's physical
volumes?
a. /dev/vg0/lv1
b. /dev/vg0/hda1
c. /dev/lv1/sda3
d. /dev/sdb3
e. None of the above

2. Which of the following would be an appropriate reference to the logical volume lv1?
a. /dev/lvm/lv1
b. /dev/vg0/lv1
c. /dev/lv1
d. /dev/hda1
e. None of the above

3. Which of the following commands is used to initialize an lvm physical volume?
a. mkpv
b. mklvm -p
c. pvmake
d. pvcreate
e. None of the above

4. What is the name of the granular unit which is used to structure the assignments of disk space to
logical volumes within a volume group?
a. sector
b. physical extent
c. block
d. chunk
e. stripe

5. Which command is used to add a physical volume to an already existing volume group?
a. vgextend
b. vggrow
c. vgadmin
d. pvcreate
e. None of the above

Use the output of the following command to answer the next two questions.
[root@station] pvdisplay /dev/sdb1
--- Physical volume ---
PV Name /dev/sdb1
VG Name vg0
PV Size 37.16 GB [7792848 secs] / NOT usable 4.1 MB [LVM: 165 KB]
PV# 1
PV Status available
Allocatable yes
Cur LV 6
PE Size (KByte) 4096
Total PE 9511
Free PE 2
Allocated PE 9509
PV UUID ptzILn-vnWA-SmcN-fu2m-Bsjt-MUO6-67tjDT

6. What is the name of the volume group to which this physical volume has been contributed?
a. /dev/sda2
b. ptzILn-vnWA-SmcN-fu2m-Bsjt-MUO6-67tjDT
c. vg0
d. Not enough information is provided.

7. What is the size of the physical extents for the physical volume?
a. 1 kilobyte
b. 4 kilobytes
c. 9511 kilobytes
d. 4 megabytes
e. Not enough information is provided.

Use the output of the following command to answer the next two questions.
[root@station] vgdisplay vg0
--- Volume group ---
VG Name vg0
VG Access read/write
VG Status available/resizable
VG # 0
MAX LV 256
Cur LV 6
Open LV 5
MAX LV Size 255.99 GB
Max PV 256
Cur PV 1
Act PV 1
VG Size 37.15 GB
PE Size 4 MB
Total PE 9511
Alloc PE / Size 9509 / 37.14 GB
Free PE / Size 2 / 8 MB
VG UUID GonJxd-GLBD-XFWC-2zuU-JM8Q-isye-3B345B

8. How much space is available for assignment to a logical volume?
a. 4 megabytes
b. 37.15 gigabytes
c. 0.25 megabytes
d. 8 megabytes
e. None of the above

9. Which of the following must be specified when creating a logical volume?
a. The name of the logical volume
b. The size of the logical volume
c. The size of a physical extent within the volume
d. A and B
e. All of the above

10. Which of the following can be created at install time using the Red Hat Enterprise Linux installer?
a. Physical volumes
b. Volume Groups
c. Logical Volumes
d. A and C
e. A, B and C
Questions
1. Which of the following can be encrypted with LUKS?
a. ext4 filesystems
b. swap partitions
c. msdos filesystems
d. Answers A and B
e. All of the above

2. Which of the following devices can be encrypted with LUKS?
a. Physical partitions
b. NFS mounts
c. Logical volumes
d. Answers A and C
e. All of the above

3. Which is the correct order for preparing an encrypted device?
a. Create the partition, format for encryption, unlock the partition, create a filesystem, mount
the filesystem
b. Create the partition, create a filesystem, encrypt the filesystem, unlock the partition, mount
the filesystem
c. Create the partition, unlock the partion, create the filesystem, mount the filesystem, encrypt
the filesystem
d. Create the partition, create the filesystem, mount the filesystem, unlock the partition, encrypt
the filesystem
e. Create the partition, format for encryption, mount the device, create the filesystem, unlock
the filesystem

4. Which command encrypts the device?
a. cryptsetup formatLuks
b. cryptsetup lockLuks
c. cryptsetup luksFormat
d. cryptsetup isLuks
e. cryptsetup luksClose

5. Which command is used to manually unlock an encrypted device?
a. cryptsetup luksFormat
b. cryptsetup unlockLuks
c. cryptsetup luksUnlock
d. cryptsetup luksOpen
e. cryptsetup isLuks

6. What file holds the mappings for encrypted devices?
a. /etc/crypttab
b. /etc/lukstab
c. /etc/fstab
d. /etc/sysconfig/crypt
e. /etc/sysconfig/luks

You might also like