guia repaso comandos prueba completa

Upload: christofer-vargas-martinez

Post on 15-Oct-2015

356 views

Category:

Documents


0 download

TRANSCRIPT

Hardwareand Device ConfigurationQuestions

1. Which process types are supported by Red Hat Enterprise Linux?a. Intel and AMD x86 32 bit processorsb. Intel and AMD x86 64 bit processorsc. IBM s/390 processorsd. IBM series Z processorse. 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/hdbb. /dev/ubbc. /dev/sdbd. /dev/usbbe. 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/messagesb. /var/log/boot.logHardware Overviewrha130-6.1-1 12 Copyright 2011, Red Hat Inc.c. /var/log/dmesgd. /var/log/kloge. None of the above

5. Which command displays the current contents of the kernel's dmesg buffer?a. klogb. kmesgc. kdumpd. dloge. None of the above

6. What command can be used to monitor hardware changed dynamically?a. monitor -hwb. lshwc. watchhwd. hwmonitore. lshal m

Use the following transcript to answer the next 4 questions.[root@station root]$ cat /proc/cpuinfoprocessor : 0vendor_id : GenuineIntelcpu family : 6model : 8model name : Pentium III (Coppermine)stepping : 3cpu MHz : 797.435cache size : 256 KBfdiv_bug : nohlt_bug : nof00f_bug : nocoma_bug : nofpu : yesfpu_exception : yescpuid level : 2wp : yesflags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr ssebogomips : 1592.52[root@station root]$ cat /proc/meminfoMemTotal: 255184 kBMemFree: 52280 kBBuffers: 24436 kBCached: 90608 kBSwapCached: 6532 kB...SwapTotal: 521632 kBSwapFree: 504940 kB[root@station root]$ cat /proc/scsi/scsiAttached devices:Host: scsi0 Channel: 00 Id: 00 Lun: 00Hardware Overviewrha130-6.1-1 13 Copyright 2011, Red Hat Inc.Vendor: ATA Model: ST9500325AS Rev: 0005Type: Direct-Access ANSI SCSI revision: 05Host: scsi1 Channel: 00 Id: 00 Lun: 00Vendor: hp Model: DVDRAM GT30L Rev: mP04Type: CD-ROM ANSI SCSI revision: 05Host: scsi4 Channel: 00 Id: 00 Lun: 00Vendor: SanDisk Model: Cruzer Mini Rev: 0.2Type: Direct-Access ANSI SCSI revision: 02

7. In general terms, what is the speed of the processor?a. 800 megahertzb. 256 megahertzc. 1.6 gigahertzd. 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 kilobytesb. 128 megabytesc. 256 megabytesd. 512 megabytese. None of the above

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

10. Who manufactured the CDROM drive?a. ATAb. SANDISKc. Inteld. HPe. Not enough information is provided.

Questions1. 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 -xKernel and Kernel Modulesrha130-6.1-1 22 Copyright 2011, Red Hat Inc.b. modules -rc. modprobe -rd. rm /proc/modules

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

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

3. Which of the following would be a conventionally named static kernel image?a. /boot/image-2.6.32-8b. /boot/zimage-2.6.32-8c. /boot/vmlinux-2.6.32-8d. /boot/vmlinuz-2.6.32-8e. 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 -lb. modulesc. lsmodd. cat /proc/kmod

6. Which command can be used to request the insertion of a kernel module?a. modules -ib. modprobec. vmlinuzd. linux m

7. What configuration file is examined whenever modprobe inserts a module?a. /etc/modprobed/*.confb. /etc/sysconfig/modulesc. /boot/modules/modprobe.confd. /etc/modtab

8. Which file contains values for /proc/sys/ directory entries which are set automatically atboottime?a. /etc/sysctl.confb. /etc/proc.confc. /etc/sysconfig/procd. /etc/systab

9. After editing the file mentioned in the previous question, what command can be run to immediatelyimplement the changes?a. procctl -sb. kernelctl -ic. setprocd. sysctl p

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

Questions1. Which of the following commands conveniently lists all connected PCI devices?a. listpcib. pcidumpc. dmesgd. kudzue. lspci

Use the following transcript to answer the next 2 questions.[root@station root]$ cat /proc/interruptsCPU00: 29957960 XT-PIC timer1: 78565 XT-PIC keyboard2: 0 XT-PIC cascade5: 75302119 XT-PIC eth08: 1 XT-PIC rtc9: 0 XT-PIC Intel ICH 82801AAPCI Devicesrha130-6.1-1 30 Copyright 2011, Red Hat Inc.11: 198578 XT-PIC usb-uhci, eth114: 258317 XT-PIC ide015: 20398 XT-PIC ide1NMI: 0ERR: 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 dayse. 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/ioportsb. /var/log/ioportsc. /etc/sysconfig/ioportsd. /var/state/ioportse. /proc/ioports5. Which of the following files lists the physical addresses of currently mapped memory (includingRAM and other devices)?a. /proc/slabinfob. /proc/meminfoc. /proc/iomemd. /var/log/meminfoe. /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 Devicesrha130-6.1-1 31 Copyright 2011, Red Hat Inc.Subsystem: Intel Corp. 82801AA USBFlags: bus master, medium devsel, latency 0, IRQ 11I/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 b1bfFlags: bus master, medium devsel, latency 0, IRQ 9I/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 0017Flags: bus master, 66Mhz, medium devsel, latency 64, IRQ 10Memory at 41000000 (32-bit, non-prefetchable) [size=16M]Memory at 44000000 (32-bit, prefetchable) [size=32M]Expansion ROM at [disabled] [size=64K]Capabilities: [60] Power Management version 1Capabilities: [44] AGP version 2.0...6. What IRQ is the USB controller using?a. 32b. 9c. 10d. 11e. 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 portsb. 41000000c. 2440d. 2000 and 2400e. Not enough information is provided

8. How much of the video card's memory has been mapped into the system?a. 16 megabytesb. 32 megabytesc. 48 megabytesd. 41000000 bytese. 44000000 bytes

Use the following transcript to answer the next question.[root@station root]$ cat /etc/modprobe.d/custom.confalias parport_lowlevel parport_pcalias eth0 8139tooPCI Devicesrha130-6.1-1 32 Copyright 2011, Red Hat Inc.alias snd-card-0 i810_audioalias usb-controller usb-uhci

9. Which kernel module is the device driver for the network interface card associated with theinterface eth0?a. Network interface device drivers are always compiled into the static kernel image.b. usb-uhcic. i810_audiod. 8139tooe. Not enough information is provided.

10. file lists modules loaded on the system?a. /proc/devicesb. /proc/modules/devicesc. /proc/hwd. /proc/lsmode. /proc/hwdevices

Questions1. What two types of filesystem device nodes exist in Linux?a. character and block device nodesb. major and minor device nodesc. hard and soft device nodesd. hot and cold device nodese. 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/fd0brw-rw---- 1 root floppy 2, 1 Jan 30 2003 /dev/fd1brw-rw---- 1 root floppy 2, 2 Jan 30 2003 /dev/fd2brw-rw---- 1 root floppy 2, 3 Jan 30 2003 /dev/fd3brw-rw---- 1 root floppy 2, 128 Jan 30 2003 /dev/fd4brw-rw---- 1 root floppy 2, 129 Jan 30 2003 /dev/fd5brw-rw---- 1 root floppy 2, 130 Jan 30 2003 /dev/fd6brw-rw---- 1 root floppy 2, 131 Jan 30 2003 /dev/fd7

2. What is the length of the file /dev/fd4?a. 2 bytesb. 128 bytesc. 128 kilobytesd. 4 kilobytese. The question is meaningless, because /dev/fd4 is a device node.

3. What type of file is /dev/fd2?a. symbolic linkFilesystem Device Nodesrha130-6.1-1 40 Copyright 2011, Red Hat Inc.b. character device nodec. block device noded. directorye. None of the above

4. What is the major number of the file /dev/fd7?a. 7b. 131c. 2d. Not enough information is providede. 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/tty0crw--w---- 1 root tty 4, 1 Oct 28 02:55 /dev/tty1crw------- 1 root root 4, 2 Oct 24 17:40 /dev/tty2crw------- 1 root root 4, 3 Oct 24 17:44 /dev/tty3crw------- 1 root root 4, 4 Oct 24 17:44 /dev/tty4crw------- 1 root root 4, 5 Oct 24 17:44 /dev/tty5crw------- 1 root root 4, 6 Oct 24 17:44 /dev/tty6crw--w---- 1 root root 4, 7 Jan 30 2003 /dev/tty7crw--w---- 1 root root 4, 8 Jan 30 2003 /dev/tty8crw--w---- 1 root root 4, 9 Jan 30 2003 /dev/tty9

5. What type of file is the file /dev/tty8?a. regular fileb. block device nodec. symbolic linkd. directorye. none of the above

6. What is the major number of the file /dev/tty3?a. 3b. 1c. 4d. 8e. 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 ttyb. root onlyc. root and members of the group consoled. all userse. not enough information is provided

8. Which of the following files is the device node for the CDROM drive?a. /dev/cdb. /dev/sr0c. /proc/scsi/sr0d. /proc/scsi/cdrome. 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/sd2b. /dev/sdcc. /proc/scsi/sdcd. Not enough information is providede. 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/usbb. mknod /dev/usbc. No command needs to be run. USB devices do not use separate device nodesd. No command needs to be run. udev will create the device node automaticallye. No command can be run. All device nodes are created at installation.

Questions1. What is the name of the utility which displays a dynamically updated list of processes currentlyrunning on the machine, as well as CPU and memory utilization statistics?a. topb. monitorc. vmstatd. pse. None of the above

Use the following transcript to answer the next 2 questions.[root@station root]$ uptime05: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 Monitoringrha130-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 hoursb. 8.87 hoursc. 12 hoursd. 2 hourse. 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.48Tasks: 86 total, 79 sleeping, 7 running, 0 zombie, 0 stoppedCpu(s): 20.0%us, 79.8%sy, 0.4%ni, 0.0%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%stMem: 255184k total, 247244k used, 7940k free, 91620k buffersSwap: 521632k total, 20756k used, 500876k free, 67012k cached

4. How much physical memory does the machine have?a. 512 megabytesb. 128 megabytesc. 64 megabytesd. 1024 megabytese. 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 = 163Performance Monitoringrha130-6.1-1 48 Copyright 2011, Red Hat Inc.b. 255 - 8 = 247c. 255 - 67 = 188d. 255 - 92 = 163e. 255 - 8 - (92 + 67) = 88

8. What file contains information about current memory utilization?a. /etc/memoryb. /proc/topc. /var/log/memd. /proc/meminfoe. 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.87Tasks: 87 total, 82 sleeping, 5 running, 0 zombie, 0 stoppedCpu(s): 99.0%us, 1.0%sy, 0.0%ni, 0.0%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%stMem: 255184k total, 250332k used, 4852k free, 8560k buffersSwap: 521632k total, 76584k used, 445048k free, 100384k cached

9. On average, how many processes have been running for the past few minutes?a. 0b. 2c. 5d. 87e. 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 fromthe 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.

LinuxFilesystem ManagementQuestionsUse the output from the following command to answer the next question.[root@station root]$ cat /proc/partitionsmajor minor #blocks nameng use aveq8 0 8891650 sda8 1 136521 sda18 2 3502170 sda28 3 2096482 sda38 4 1 sda48 5 2096451 sda5

1. Which of the following best explains why the partition sda4 is listed in /proc/partitionswith 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 demandplaced 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/sda7b. /dev/sdb5c. /dev/sdb4d. /dev/sdc8e. None of the above

3. Which of the following would be a logical partition?a. /dev/sda3b. /dev/sda5c. /dev/sdb1d. /dev/sdb4e. None of the above

4. Which of the following commands would list all known partitions?a. fdisk --dumpb. dumppartc. fdisk -culd. fdisk --liste. None of the above

5. Which of the following commands could be used to add the partition /dev/sda8?a. fdisk -a /dev/sda8b. fdisk -cu /dev/sda8c. fdisk -l /dev/sda8d. fdisk --add /dev/sda8e. None of the above

Use the following transcript to answer the next 3 questions.[root@station root]$ fdisk -cul /dev/sdbDisk /dev/sdb: 10.7 GB, 10737418240 bytes255 heads, 63 sectors/track, 1305 cylinders, total 20971520 sectorsUnits = sectors of 1 * 512 = 512 bytesSector size (logical/physical): 512 bytes / 512 bytesDisk Recognition and Partitioningrha130-6.1-1 20 Copyright 2011, Red Hat Inc.I/O size (minimum/optimal): 512 bytes / 512 bytesDisk identifier: 0x2f2333e8Device 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 muchpartition space is allocated to swap space?a. 128 megabytesb. 520 megabytesc. 8.4 gigabytesd. 5.5 megabytese. Not enough information is provided

7. Approximately how much space is left unallocated on the drive /dev/sdb?a. 0b. 420 megabytesc. 8.4 gigabytesd. 84 megabytese. Note enough information is provided

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

9. After editing the partition table with fdisk, what action must (usually) be taken for the kernel torecognize 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 abovee. Either A or C

10. Which of the following fdisk commands is used to abandon all changes?a. ab. qc. xd. we. z

Questions1. Which of the following filesystems is usually associated with compact disks?a. ext3b. iso9660c. reiserfsd. vfate. None of the above

2. Which of the following commands could be used to create an ext3 filesystem?a. mkfs.ext3b. mkfs -t ext3c. mke2fs -jd. mkfs.ext2 -je. All of the above

3. Which of the following command lines could be used to create an ext2 filesystem with a blocksizeof 2048 bytes?a. mke2fs -b 2048 /dev/sda4b. mke2fs /dev/sda4c. mke2fs -b2k /dev/sda4d. mke2fs -b2 /dev/sda4e. A and B

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

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

5. When creating this filesystem, which of the following would be the appropriate argument to the -icommand line switch to the mke2fs command to generate the appropriate number of inodes?a. -i 2b. -i 4096c. -i 8192d. -i 4e. 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 disablejournaling.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 fortemporary media such as floppies.d. The command line switch would cause the floppy to be overwritten with binary 0's before thefilesystem 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/sda1b. mkfs.ext2 --label=data /dev/sda1c. mkfs.ext2 -m data /dev/sda1d. mkfs -t ext2 -L data /dev/sda1e. 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/sda1b. mkfs.ext4 -b 4k /dev/sda1c. mkfs -t ext2 -j -b4 /dev/sda1d. mkfs -t ext4 --block=4k /dev/sda1e. None of the above

9. Which of the following command line switches causes the mke2fs command to check the disk forbad blocks before creating a filesystem?a. -Lb. -cc. -bd. -se. None of the above

10. Your friend has just run the dumpe2fs command on his /home filesystem, and noticed that theflag 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 recoveryalgorithm every 10 minutes.e. You do not believe him, and suspect he ran the dumpe2fs command on a partition that doesnot contain an ext2 filesystem.

Questions1. Which of the following could be a legitimate invocation of the mount command?a. mount -t /dev/sda2 /homeb. mount /home /dev/sda2c. mount /dev/sda2 /homed. mount -o /home /dev/sda2e. None of the above

2. Which of the following command lines would mount the device /dev/sda3, formatted with thevfat filesystem, to the mount point /dosc?a. mount -o vfat -d /dev/sda3 /doscb. mount -t vfat /dev/sda3 /doscc. mount -t vfat -o /dosc /dev/sda3d. mount -o vfat /dosc /dev/sda3e. None of the above

3. Which of the following is not a common Linux mount option?a. mtimeb. noatimec. noexecd. roe. 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/sda1b. /dev/sda7c. /dev/sda5d. /dev/sda3e. None of the above

5. Which partition contains the mount point /var/www/html?a. /dev/sda3b. /dev/sda7c. /dev/sda1d. /dev/sda5e. None of the above

6. When accessing the file /var/www/html/index.html, how many partitions does the kernelinvolve?a. 1b. 3c. 0d. 2e. 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/floppyumount: /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 yetbeen 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 immediatelyfollowed by the same umount command listed above, the unmount would succeed?a. fuser -m /mnt/floppyb. fsck -m /mnt/floppyc. syncd. cde. 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 /homeb. mount -a noatime /dev/sda4 /homec. mount -remount -o noatime /dev/sda4 /homed. mount -o remount,noatime /dev/sda4 /homee. 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 /homeb. umount -t ext3c. umount /dev/sdb5d. unmount -ae. None of the above

QuestionsUse the following transcript to answer the next 5 questions.[root@station root]# cat /etc/fstabLABEL=/ / ext4 defaults 1 1LABEL=/var/ftp/pub /var/ftp/pub ext4 defaults 1 2LABEL=/home /home ext4 defaults 1 2LABEL=/boot /mnt/boot ext4 defaults,noauto 1 2/dev/sda5 /dos vfat defaults,noauto,user 0 2devpts /dev/pts devpts gid=5,mode=620 0 0proc /proc proc defaults 0 0sysfs /sys sysfs defaults 0 0tmpfs /dev/shm tmpfs defaults 0 0LABEL=SWAP-sdb2 swap swap defaults 0 0/dev/fd0 /media/floppy auto user 0 01. Which of the following mount points would not be used by a mount -a command?a. /var/ftp/pubb. /dev/ptsc. /homed. /dose. 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/sda5b. mount /dosc. mount /dev/sda5 /mnt/dosd. All of the abovee. A and B only

3. Which of the following command lines would attempt to mount a filesystem to the /mnt/bootdirectory?a. mount -ab. mount /bootc. mount -L /bootd. A and Ce. 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, thefilesystem 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 isreferences.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 underlyingpartition 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. mke2fsb. fdiskc. mountd. fusere. 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 2devpts /dev/pts devpts gid=5,mode=620 0 0proc /proc proc defaults 0 0sysfs /sys sysfs defaults 0 0tmpfs /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 mustbe 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 existsas well.

9. What is suspicious about the second column of this file, which leads you to believe that there mustbe some mistake?a. Partitions are configured to be mounted to both /var/data and /var, but partitions mayonly 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 /devdirectory 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 mustbe 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 thefsck 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 issuspect.e. The column contains multiple entries for the value "1", when the value 1 is only supposed tobe used for the root partition.Questions1. What is the threshold amount of physical memory, above which allocating swap space is no longerrecommended?a. 128 megabytesManaging Swap Spacerha130-6.1-1 59 Copyright 2011, Red Hat Inc.b. 256 megabytesc. 512 megabytesd. 1 gigabytee. 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/swapsb. /etc/fstabc. /var/state/swapd. /etc/swaptabe. None of the above

3. Which file is used to define swap partitions which should be activated automatically as the systemboots?a. /etc/swaptabb. /etc/fstabc. /proc/swapsd. /var/state/swape. 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/sda3b. mkswap /dev/sda3c. mkfs -t swap /dev/sda3d. fdisk /dev/sda3e. None of the above

5. What command line would be used to initialize a file to be used as swap space?a. mkswap /tmp/swapfileb. mkswap -f /tmp/swapfilec. swapinit -f /tmp/swapfiled. mkswapfile /tmp/swapfilee. None of the above

6. ext3 is to mount as swap is to ....Managing Swap Spacerha130-6.1-1 60 Copyright 2011, Red Hat Inc.a. swaponb. mkswapc. swapsd. swapoffe. startswap

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

8. Which of the following commands is used to deactivate a swap area?a. swapstopb. umountc. uswapd. swapoffe. None of the above

9. Which of the following command lines could be used to activate a swap partition with a priorityof 3?a. mkswap -p 3 /dev/sda3; swapon /dev/sda3b. swap /dev/sda3 3c. mount -t swap -o pri=3 /dev/sda3d. swapon -p 3 /dev/sda3e. 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/swapsb. cat /proc/meminfoc. topd. cat /proc/slabinfoe. A and BQuestions1. Which of the following command lines could be used to check and repair an ext2 filesystem?a. fsck /dev/sda3b. fsck -t ext2 /dev/sda3c. fsck.ext2 /dev/sda3d. e2fsck /dev/sda3e. 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/sda3b. e2label -L /data /dev/sda3c. e2label /dev/sda3 /datad. label -t ext2 /dev/sda3 /datae. 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 Linuxinstallation. 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. Youwould 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. e2labelb. mkswapc. fdiskd. mounte. 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, swaponb. fdisk, swapon, mkswap, mke2fs, mountc. mount, fdisk, mke2fs, mkswap, swapond. fdisk, mke2fs, mkswap, mount, swapone. mkswap, swapon, mke2fs, mount, fdisk

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

6. Which of the following command lines could be used to create an ext4 filesystem on the first logicalpartition, and assign it the label /data3?a. mkfs.ext4 -L /data3 /dev/sdd5b. mkfs.ext4 /dev/sdd5; e2label /dev/sda5 /data3c. mkfs.ext4 /dev/sdd5; tune2fs -L /dev/sda5 /data3d. All of the abovee. None of the above

7. Once the ext4 filesystems have been created, and are all mounted, you decide that you would likethe filesystem on partition /dev/sdd2 to be an ext3 filesystem instead. Which command line couldbe used to convert the filesystem to ext3 (without losing any data already in the filesystem)?a. tune2fs -j /dev/sdd2b. umount /dev/sdd2 && mkfs.ext3 /dev/sdd2c. umount /dev/sdd2 && tune2fs -j /dev/sdd2d. umount /dev/sdd2 && mke2fs -j /dev/sdd2e. 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. Youunmount the partition. What command could you run next to perform the check?a. swapoff /dev/sdd3b. fsck.vfat /dev/sdd3c. fisk /dev/sdd3d. fsck /dev/sdd3e. None of the above

9. The check and repair utility used above mentions that it has restored some file, but could not findnames 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 theext3 filesystem. After successfully converting your new ext2 filesystem to ext3, what additionalcommand should be run?a. ext3initb. kudzuc. mkinitrdd. setupe. mkext3Questions1. Which of the following could be an appropriate reference to one of the volume group vg0's physicalvolumes?a. /dev/vg0/lv1b. /dev/vg0/hda1c. /dev/lv1/sda3d. /dev/sdb3e. None of the above

2. Which of the following would be an appropriate reference to the logical volume lv1?a. /dev/lvm/lv1b. /dev/vg0/lv1c. /dev/lv1d. /dev/hda1e. None of the above

3. Which of the following commands is used to initialize an lvm physical volume?a. mkpvb. mklvm -pc. pvmaked. pvcreatee. None of the above

4. What is the name of the granular unit which is used to structure the assignments of disk space tological volumes within a volume group?a. sectorb. physical extentc. blockd. chunke. stripe

5. Which command is used to add a physical volume to an already existing volume group?a. vgextendb. vggrowc. vgadmind. pvcreatee. 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/sdb1VG Name vg0PV Size 37.16 GB [7792848 secs] / NOT usable 4.1 MB [LVM: 165 KB]PV# 1PV Status availableAllocatable yesCur LV 6PE Size (KByte) 4096Total PE 9511Free PE 2Allocated PE 9509PV 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/sda2b. ptzILn-vnWA-SmcN-fu2m-Bsjt-MUO6-67tjDTc. vg0d. Not enough information is provided.

7. What is the size of the physical extents for the physical volume?a. 1 kilobyteb. 4 kilobytesc. 9511 kilobytesd. 4 megabytese. 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 vg0VG Access read/writeVG Status available/resizableVG # 0MAX LV 256Cur LV 6Open LV 5MAX LV Size 255.99 GBMax PV 256Cur PV 1Act PV 1VG Size 37.15 GBPE Size 4 MBTotal PE 9511Alloc PE / Size 9509 / 37.14 GBFree PE / Size 2 / 8 MBVG UUID GonJxd-GLBD-XFWC-2zuU-JM8Q-isye-3B345B

8. How much space is available for assignment to a logical volume?a. 4 megabytesb. 37.15 gigabytesc. 0.25 megabytesd. 8 megabytese. None of the above

9. Which of the following must be specified when creating a logical volume?a. The name of the logical volumeb. The size of the logical volumec. The size of a physical extent within the volumed. A and Be. All of the above

10. Which of the following can be created at install time using the Red Hat Enterprise Linux installer?a. Physical volumesb. Volume Groupsc. Logical Volumesd. A and Ce. A, B and CQuestions1. Which of the following can be encrypted with LUKS?a. ext4 filesystemsb. swap partitionsc. msdos filesystemsd. Answers A and Be. All of the above

2. Which of the following devices can be encrypted with LUKS?a. Physical partitionsb. NFS mountsc. Logical volumesd. Answers A and Ce. 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, mountthe filesystemb. Create the partition, create a filesystem, encrypt the filesystem, unlock the partition, mountthe filesystemc. Create the partition, unlock the partion, create the filesystem, mount the filesystem, encryptthe filesystemd. Create the partition, create the filesystem, mount the filesystem, unlock the partition, encryptthe filesysteme. Create the partition, format for encryption, mount the device, create the filesystem, unlockthe filesystem

4. Which command encrypts the device?a. cryptsetup formatLuksb. cryptsetup lockLuksc. cryptsetup luksFormatd. cryptsetup isLukse. cryptsetup luksClose

5. Which command is used to manually unlock an encrypted device?a. cryptsetup luksFormatb. cryptsetup unlockLuksc. cryptsetup luksUnlockd. cryptsetup luksOpene. cryptsetup isLuks

6. What file holds the mappings for encrypted devices?a. /etc/crypttabb. /etc/lukstabc. /etc/fstabd. /etc/sysconfig/crypte. /etc/sysconfig/luks