Linux Administration
Linux Administration
A. Type
B. Find
C. File
D. Ls
Answer: C
2. Which command will list all the files installed from the RPM package file named, vorbis-tools-
1.1 .i386.rpm?
A. rpm-qfvorbis-tools-1.1 .i386.rpm
B. rpm -F vorbis-tools-1.1 .i386.rpm
C. rpm -pf vorbis-tools-1.1 .i386.rpm
D. rpm -ql vorbis-tools-1.1.1386.rpm
E. rpm-qlp vorbis-tools-1.1.1386.rpm
Answer: D
3. What key combination is used to forcibly halt the X server in the event of the graphical session
becoming unusable (eg., desktop manager or fullscreen application hanging)?
A. press CTRL+ALT+DEL
B. press CTRL+ALT+BACK_SPACE
C. press CTRL+ALT+DEL twice
D. press CTRL+ALT+F1 then run
Answer: B
4. Which of the following commands will print the inode usage on each mounted filesystem?
A. du -i
B. df -i
C. lsfs -i
D. printfs -i
Answer: B
5. While using the vi editor, you wish to move ahead one page. You should press the control key
and:
A. A
B. D
C. F
D. U
Answer: F
6. How can you turn off the group quota in /pub?
A. quotaoff/pub
B. quotaoff-gv/pub
C. quotadown /pub
D. rm/pub/quota.group
Answer: B
7. When you start XWindows, which series of programs and/or scripts would most closely describe
the start-up process?
Answer: D
8. In GRUB's configuration file an administrator finds the following line: root (hd1,4) Which of the
following is the corresponding device name on a Linux system?
A. /dev/hda4
B. /dev/hda5
C. /dev/hdb4
D. /dev/hdb5
Answer: D
9. While using the vi editor, you wish to move ahead one page. You should press the control key
and:
A. A
B. D
C. F
D. U
Answer: C
A. /sbin/mke2fs -d /dev/hda2
B. /sbin/mke2fs -j /dev/hda2
C. /sbin/mke2fs -m 3 /dev/hda2
D. /sbin/mke2fs -c ext3 /dev/hda2
Answer: B
11. Which RPM command will output the name of the package which installed the file /etc/exports?
A. rpm -F /etc/exports
B. rpm -qf /etc/exports
C. rpm -Kl /etc/exports
D. rpm -qp /etc/exports
E. rpm -qi /etc/exports
Answer: B
12. You logged in as user tuxl, but now you want to switch users to tux2 with tux2's environment.
How would you do this?
A. su tux2
B. su-etux2
C. su – tux2
D. su – m tux2
E. su-ftux2
Answer: C
Answer: B
14. You are the system administrator for a consulting firm where several people use Linux as their
desktop operating system. One of your users has installed a commercial publishing program that
works under X on a variety of UNIX and Linux platforms. The user made a series of
configuration changes regarding the initial window size, location and color. Now, he is having
difficulty undoing these changes and is asking for your help. In which file would you think you
would most likely find the configuration settings you are seeking to change?
A. ~/.xinitrc
B. ~/.xconfig
C. ~/.Xdefaults
D. ~/.XF86Config
E. ~/.XF86Config
F. /etc/X11/XF86Config
Answer: C
15. All items are required to enable USB support on a Linux system EXCEPT:
Answer: B
16. You enter the command date +%M. What does the output show you?
Answer: D
17. Keyboards and mice are members of which class of USB devices?
Answer: B
18. You have not run apt-get on a system for some time, but it has been run on the system before.
What apt-get command would you run to download the latest list of packages, but not the
packages themselves?
A. apt-getbuilD.dep
B. apt-get mirror-select
C. apt-get update
D. apt-get upgrade
E. apt-get dist-upgrade
Answer: D
19. You have finished updating and resolving dependencies for some source code. What command
should you run before recompiling the code into binary form?
A. Make clean
B. Make all
C. Make dep
D. Make install
Answer: A
20. The command mkfs -t ext3 -T largefile /dev/hdb1 creates what size of inode?
A. 4 kilobyte
B. 1 megabyte
C. 2 megabyte
D. 4 megabyte
Answer: B
21. The user john is no longer working for a company. To disable his account but not delete his
information, what needs to be done?
A. userdeljohn
B. userdisablejohn
C. Remove user john from /etc/shadow.
D. Replace his password with * in passwd
E. Replace his password with a space in passwd.
Answer: D
Answer: D
Answer: D
24. You suspect that a gateway machine on your network has failed but you are unsure which
machine. Which command will help locate the problem?
A. Ps
B. Netstat
C. Nslookup
D. Ifconfig
E. Traceroute
Answer: E
A. Shutdown –c –r now
B. Fsck –r
C. Shutdown –f –r now
D. Shutdown –f now
E. Reboot –f
Answer: C
26. A user is unable to access the Internet from their Client. The client's TCP/IP settings are
192.168.1.87/26. The default gateway's IP address is 192.168.1.1. What command must be
entered on the client machine to enable communications to the Internet?
Answer: A
A. SMTP
B. DNS
C. FTP
D. SSH (Secure Shell)
Answer: D
Answer: B
29. A computer has a FAT32 partition that takes up the entire 16 GB hard drive. Another operating
system is currently installed, but only uses 8 GB of the partition. What is the best way to install
Linux without removing the other operating system?
A. Run FIPS
B. Run rsize
C. Run fdisk
D. Run format
Answer: A
Answer: A
31. A customer needs a Linux server to act as a Microsoft Windows NT domain controller. Which of
the following must be installed for this server?
A. Syslog daemon
B. Network file system daemon
C. Server message block daemon
D. File transfer protocol daemon
Answer: C
32. A customer wants to determine which TCP ports are in use on his Linux server. Which of the
following commands should be used?
A. Tftp
B. Lsport
C. Minicom
D. Netstat
Answer: D
33. Which of the following commands is used to obtain the summary of hard disk partitions?
A. Fsck
B. Fdisk
C. Fsck –l
D. Fdisk –l
Answer: D
34. Which of the following information is NOT returned by ifconfig on a machine connected to an
Ethernet network?
A. IP address
B. MAC address
C. Computer hostname
D. Active network interfaces
Answer: C
35. An administrator needs to maintain a log of work performed on a Linux server. Which of
following written records is the most important to maintain?
Answer: A
A. :ZZ
B. :q!
C. :QQ
D. Esc-q
Answer: B
37. An Internet Web server is being installed. No DHCP server is available. What is the proper
method to obtain a valid Internet IP address?
A. Use ping
B. Use netstat
C. Use nslookup
D. Contact the Internet Service Provider (ISP)
Answer: D
38. Which cp command option will cause the copy to happen only when the source file es newer
than the destination file or when the destination file is missing?
A. –a
B. –l
C. –s
D. –u
Answer: D
39. What is the command to display the IP address setup of all network interfaces on the computer?
A. Ip show
B. Ip display
C. Ip address display
D. Ip address show
E. Ip network display
Answer: D
40. Which commmand will list hidden files in a directory for a normal user?
A. Ls
B. Ls –a
C. Ls –h
D. Ls –l
E. Ls –u
Answer: B
A. /init/grub/menu.lst
B. /etc/grub/menu.lst
C. /sys/grub/menu.Ist
D. /root/grub/menu.lst
E. /boot/grub/menu.lst
Answer: E
42. Which keystroke switches the vi editor from insert mode back to command mode?
A. $
B. #
C. :
D. >
E. ~
F. Esc
Answer: F
43. How can you switch between virtual terminals on your computer?
A. Fx
B. SHFT –Fx
C. CTRL –Fx
D. CTRL –ALT –Fx
E. Rhae TAB key
Answer: D
44. After the integration of SUSE Linux Enterprise 10 into an Active Directory environment, what is
the command to change your Windows password from the local Linux machine?
A. Pass
B. Passwd
C. Winpass
D. Password
E. You cannot change the password from the local Linux machine
Answer: B
45. In the vi editor, which commands will save the file and end vi?
A. :e
B. :w
C. :q!
D. :wq
Answer: D
46. Which of the following is the purpose of the Bash built-in export command?
Answer: D
Answer: D
48. After modifying LILO's configuration file, which of the following commands should be run for the
changes to take effect?
Answer: D
49. In order to append the output of ls to a file called bazz, which of the following command lines
would an administrator use?
A. ls > bazz
B. ls >& bazz
C. ls &> bazz
D. ls >> bazz
Answer: D
50. To allow a regular user account to mount and unmount a filesystem (for instance, a cdrom or
floppy), which of the following options will need to be added to the corresponding line in
/etc/fstab?
A. nouidchk
B. alluser
C. user
D. auto
Answer: C
51. Bob accidentally created the subdirectory \bobsdir in his home directory. He tried to remove the
subdirectory with the command rmdir \bobsfile only to receive the error, "No such file or
directory." . Which of the following commands will remove the directory?
A. rmdir '~bob/\bobsdir'
B. rmdir "~bob/\bobsdir"
C. rmdir ~bob/'bobsdir'
D. rmdir ~bob/\bobsdir
E. rmdir ~bob/\\bobsdir
Answer: E
52. All of the following commands will update the Modify timestamp on the file /tmp/myfile.txt
EXCEPT:
A. file /tmp/myfile.txt
B. echo "Hello" >/tmp/myfile.txt
C. sed -ie "s/1/2/" /tmp/myfile.txt
D. echo -n "Hello" >/tmp/myfile.txt
E. touch /tmp/myfile.txt
Answer: A
53. An administrator has just added a CD-ROM drive (/dev/hdd) to a system and added it to the
administrator's fstab. Typically the administrator can use which of the following commands to
mount media in that drive to /mnt/cdrom?
Answer: D
54. The Linux kernel is loaded successfully by the boot loader. However, straight after the kernel
mounts the root filesystem, the boot process stops and an error message regarding init is
shown. Which of the following actions is the best one to be used in order to identify and fix the
problem?
A. The administrator reboots the system with a recovery disk and checks the root file system for
errors with fsck.
B. The administrator reboots the system with a recovery disk and restores from a backup.
C. The administrator reboots the system and tells the kernel, through the boot loader prompt, to
use /bin/bash as the initial process.
D. The administrator reboots the system with a recovery disk and installs a new kernel.
Answer: A
55. Where should the LILO code reside, on a system with only one installation of Linux and no other
operating systems?
Answer: D
A. shutdown -c -r now
B. fsck -r
C. shutdown -F -r now
D. shutdown -f now
E. reboot -f
Answer: C
57. You suspect that a gateway machine on your network has failed but you are unsure which
machine. Which command will help locate the problem?
A. netstat
B. nslookup
C. ifconfig
D. traceroute
Answer: D
58. Identify the statement that would create a default route using a gateway of 192.168.1.1.
Answer: C
59. Of the ways listed, which is the best way to temporarily suspend a user's ability to interactively
login?
60. Which shell built-in command can be used to create a shortcut or pseudonym for a longer
command? Assume a modern bournE.like shell, such as bash.
A. shortcut
B. sudo
C. link
D. alias
Answer: D
61. You have just added a CD.ROM drive (/dev/hdd) to your system and have added it to yourfstab.
Typically you can use which of the following commands to mount media in that drive to
/mnt/cdrom?
Answer: D
A. RAID4
B. RAID5
C. RAID1
D. RAID0
Answer: C
63. Which of the following commands should be used to allow SSH (Secure Shell) to connect to a
server with IP address 192.168.0.100?
Answer: C
64. Which of the following commands will add a user to a group from a Telnet session?
A. groupuse
B. useradd
C. groupset
D. user2group
Answer: B
65. A Linux server is to be used as a Web server. Which of the following is the BEST way to
configure its Ethernet adapter?
A. Use an IP alias.
B. Configure the DHCP Server.
C. Configure the DHCP Client.
D. Use a static IP address.
Answer: D
66. Which driver, if any, is required to support L3 cache on the system processor?
A. No driver is required.
B. mtrr.o
C. cache.o
D. msr.o
Answer: A
67. An administrator wants to temporarily disable the eth0 network interface on a server. Which of
the following commands will accomplish this?
A. ifconfig disable
B. ifconfig eth0 disable
C. ifconfig eth0 down
D. ifconfig eth0 off
Answer: C
68. Which of the following can be used to view username, UID (User ID), GID (Group ID), full name,
home directory, and default shell information?
A. cat /etc/services
B. cat /etc/shadow
C. cat /etc/group
D. cat /etc/passwd
Answer: D
69. A company wants to install a Linux server to act as an internal file and print server. They have a
limited budget. Which of the following is the MOST important hardware investment for this user?
A. Video card
B. IEEE-1394 card
C. Processor
D. Hard drive
Answer: D
70. The UMASK value is set to 22 Which of the following will the default permissions be on
lilename.txt when the file is created?
A. rwxr-xr-x
B. ----w--w-
C. r-xr-wr-w
D. rw-r--r--
Answer: D
71. A user who is installing Linux inserts the install CD-ROM and then reboots the computer.
However, the computer boots into Windows. Which of the following MOST likely caused the
problem?
Answer: B
72. Six Linux servers share a tape library in a different room located 80 meters away. Which of the
following technologies would allow these servers to connect directly to the tape library?
A. IEEE-1394
B. Single-Ended SCSI
C. Differential SCSI
D. Fibre Channel
Answer: D
73. Which of the following commands allows an administrator to add an existing user's phone
number to the system as a comment?
Answer: B
74. Which backup type only copies files that have changed since the previous backup?
A. Full
B. Modular
C. Incremental
D. Partial
Answer: C
75. Which of the following is the function of the ARP (Address Resolution Protocol)?
Answer: B
76. Which of the following will happen when the following command is run? userdel johnd
A. The user johnd is removed from the system and all data in the home directory is moved to the
/home/deletedusers directory.
B. The user johnd is removed from the system, deleting all of the data in his home directory.
C. The user johnd is removed from the system while keeping all of the data in his home
directory.
D. The user johnd is removed from the system and all of his data is moved to the /var/archive
directory.
Answer: C
77. A production Web server is experiencing an unusually large amount of new incoming TCP
connections. Which of the following is MOST likely the problem?
A. NIC malfunction
B. DoS (Denial of Service)
C. Virus
D. Too many users
Answer: B
78. Which of the following commands can be used to hide the file "help.new"?
A. atrrib -h help.new
B. mv help.new .help.new
C. cp help.new .help.new
D. chmod 4000 help.new
Answer: B
79. A technician needs to extract the entire archive 'backup.tar.bz2'. Which of the following
commands will accomplish this?
Answer: C
80. Which of the following group-level permissions is needed to create user accounts?
A. ntadmin
B. adm
C. nobody
D. root
Answer: D
81. Which of the following commands will create the directory /home/gawd/tools/security regardless
of the existence of its parent directories?
A. mkdir -m /home/gawd/tools/security
B. mkdir --makepath /home/gawd/tools/security
C. mkdir -p /home/gawd/tools/security
D. md -m /home/gawd/tools/security
Answer: C
82. The administrator must change the IP address of the server to 192.168.5.4/26. Which of the
following is the correct representation of the subnet mask?
A. 192.168.5.255
B. 255.255.255.0
C. 192.168.5.0
D. 255.255.255.192
Answer: D
83. After a power outage, a Linux machine reboots but fails to mount all of its file systems. The file
systems are unable to be mounted manually. Which of the following should be done FIRST?
A. Reboot to runlevel 6.
B. Run fsck on each file system and try to mount again.
C. Reinstall the operating system.
D. Edit /etc/fstab and correct any problems identified.
Answer: B
84. A Linux system will not boot, even in single-user mode, but hard drive diagnostics indicate that
the drive is working properly. Which of the following should be done to repair the file system?
A. Use a bootable Linux medium to boot into Linux and run fdisk.
B. Use a bootable Linux medium to boot into Linux and run fsck.
C. Reinstall Linux from the original install drive and apply all patches.
D. Use the custom tool provided by the hard drive manufacturer.
Answer: B
85. What Linux service is responsible for successfully sharing files over a NetBIOS network?
A. NFS
B. Samba
C. XFree86
D. Xwindows
Answer: B
86. Which of the following strings indicates that the input of the program called printData should be
redirected from the file called "myData"?
A. printData . myData
B. printData > myData
C. printData < myData
D. printData | myData
Answer: C
87. What is the difference between "shutdown -h now" and "init 0"?
Answer: C
88. A Linux system administrator has forgotten the root password. Which of the following would be
the best way for the system administrator to gain access to the machine?
A. Reinstall Linux.
B. Enter runlevel 0 and run passwd.
C. Reboot and use the mdrecovery utility.
D. Reboot, enter Linux single-user mode and run passwd.
Answer: D
89. Which of the following commands will create 'bsmith' as a user in the group 'web_users'?
Answer: B
A. /bin
B. /etc
C. /tmp
D. /var
Answer: D
A. ssh
B. ftp
C. http
D. telnet
Answer: A
92. Which of the following commands is issued to create the group 'sqleditors' on a system?
A. group +sqleditors
B. addgroup sqleditors
C. groupadd sqleditors
D. echo sqleditors:x:601: > /etc/groups
Answer: C
93. A user calls into the support line and reports that he is unable to unlock his desktop. After
several attempts, he is sure that he has entered his password correctly. What is the first thing to
do to troubleshoot this situation?
Answer: B
94. A Linux system is used for various Internet services and remote user access. When a problem
arises with one of that machine's services, which of the following actions is the LEAST likely to
disrupt other services on that machine?
A. Kill a daemon
B. Reboot the machine
C. Change to runlevel 1
D. Disable a network device
Answer: A
95. A package that a user installed has never run successfully and returns a large number of errors.
What is the first action that should be taken?
Answer: B
96. During installation of a Linux system, the customer decided to use the
ReiserFS file system rather than ext2. What is the most likely reason for this choice?
Answer: B
97. The user installs the second SCSI hard drive into the computer and needs to partition it. Which
of the following commands must be run to partition the disk?
A. fdisk /dev/hdb
B. fdisk /dev/hd2
C. fdisk /dev/sdb
D. fdisk /dev/sd2
Answer: C
98. A customer wants to backup her entire Website into a file. Which of the following commands
would best accomplish this?
Answer: A
99. Which of the following commands can be used to go to the 25th line of a file in vi?
A. :25
B. 25g
C. G25
D. g25
Answer: A
100. While a technician was installing Linux on a customer's server, the customer asked for
the ability to expand the partition size, as needed. Which of the following would best provide this
ability?
A. HPFS
B. ext2
C. FAT32
D. ReiserFS
Answer: D