TD - Préparation à la certification LPIC-1

Page 1 sur 15Lecteur de document UniversityLib

TD - Préparation à la certification LPIC-1

Linux System Administration · exam

Browse all systèmes d'exploitation et cloud documents

TD - Préparation à la certification LPIC-1

Objectifs 101 et 102

1) Les claviers et les souris font partie de quelle classe des périphériques usb?

A- Communication

B- Interface Homme Machine

C- Stockage de masse

D- Interface de données

2) Que fait la commande mount -a ?

A- Monte la disquette pour tous les utilisateurs

B- Affiche tous les systèmes de fichiers montés

C- Ouvre /etc/fstab pour édition

D- Monte tous les systèmes de fichiers listés dans /etc/fstab

3) Identifier le bon périphérique pour la 3ème partition sur le 2ème disque dur sur le

premier contrôleur IDE

A- /dev/hdb3

B- /dev/hdlb3

C- /dev/hdc2

D- /dev/hd2c

4) Laquelle des commandes suivantes vous permet d’utiliser les librairies partagées

situées dans /usr/local/lib

A- export LD_PRELOAD=/usr/local/lib

B- ldconfig /usr/local/lib

C- export LD_LIBRARY_PATH=/usr/local/lib

D- ldd /usr/local/lib

5) Quel fichier est utilisé par ld.so pour trouver rapidement les librairies sans avoir à

chercher dans les répertoires indiqués dans ses chemins?

A- /etc/ld.so.cache

B- /etc/ld.so.conf

C- /etc/ld.so

D- /var/ld/cache

E- /var/.cache

6) You want to preview where the package file, apache-xml.i386.rpm, will install its files

before installing it. What command do you issue?

A. rpm -qp apache-xml.i386.rpm

B. rpm -qv apache-xml.i386.rpm

C. rpm -ql apache-xml.i386.rpm

D. rpm -qpl apache-xml.i386.rpm

7) Which system administration command you can use to update ld.so.cache after the

installation of new shared libraries?

A. ldconfig

B. ldd

C. libpath

D. newlibs

8) How do you get a list of files that have been installed from a dpkg package?

A. dpkg -l pkgname

B. dpkg -C pkgname

C. dpkg -s pkgname

D. dpkg -S pkgname

E. dpkg -L pkgname

9) What RPM command would show you detailed information for a package called

openssh-3.6.i386.rpm?

A. rpm --showinformation openssh-3.6.i386.rpm

B. rpm --showdetails --package openssh-3.6.i386.rpm

C. rpm --query --info --package openssh-3.6.i386.rpm

D. rpm --verify openssh-3.6.i386.rpm

10) In GRUB's configuration file you find the line

Root (hd1,4)

What is corresponding device name on a Linux system?

A. /dev/hda4

B. /dev/hda5

C. /dev/hdb4

D. /dev/hdb5

11) Which configuration file should be modified to disable the ctrl-alt-delete key

combination?

A. /etc/keys

B. /proc/keys

C. /etc/inittab

D. /proc/inittab

E. /etc/reboot

12) You are having some trouble with a disk partition and you need to do maintenance on

this partition but your users home directories are on it and several are logged in. Which

command would disconnect the users and allow you to safely execute maintenance

tasks?

A. telinit 1

B. shutdown -r now

C. killall -9 inetd

D. /bin/netstop --maint

E. /etc/rc.d/init.d/network stop

13) The message "Hard Disk Error" is displayed on the screen during Stage 1 of the GRUB

boot process. What does this indicate?

A. The kernel was unable to execute/bin/init

B. The next Stage cannot be read from the hard disk because GRUB was unable to

determine the size and geometry of the disk

C. One or more of thefilesystems on the hard disk has errors and a filesystem check should

be run

D. The BIOS was unable to read the necessary data from the Master Boot Record to begin

the boot process

14) Which of the following commands can be used to instruct the init process to switch

runlevels? (Choose TWO correct answers)

A. telinit

B. initctl

C. init

D. reinit

E. runlevel

15) To prevent users from being able to fill up the / partition, the _________ directory should

be on a separate partition if possible because it is world writeable.

_______________

16) Upon booting one of your Linux boxes, you notice a message scrolling by that does not

look right, but it goes so fast, you do not have a chance to read it. What command could

you use to view that message after the boot process completes?

_______________

17) What file contains kernel level logging information such as output from a network driver

module when it is loaded?

_______________

18) The USB device filesystem can be found under /proc/ _______ /usb/. (Please fill in the

Advertisement

blank with the single word only)

_______________

19) Which user-level program, when manually executed by the root user, is used to change

the runlevel of the system? (Provide only the command with no additional options or

parameters)

_______________

20) The lspci command can display information about devices except the following:

A. Card bus speed (e.g. 66Mhz)

B. Card IRQ settings

C. Card vendor identification

D. Card AGP rate (e.g. 1x, 2x, 4x)

E. Card Ethernet MAC address

21) What command would help you identify the I/O address range being used by the

network card?

A. cat /proc/modules

B. cat /proc/devices

C. cat /proc/meminfo

D. cat /io/dma

E. cat /proc/ioports

22) You need to know where all the configuration files for the installed package named

"postfix" are located. Assuming it was installed with rpm, which command will list this

information for you?

A. rpm -qc postfix

B. rpm -Vc postfix

C. rpm --config postfix

D. rpm -listconfig postfix

E. rpm -qa --config postfix

23) What tool can you use to print shared library dependencies?

A. ldconfig

B. ldd

C. libdep

D. libpath

E. ldev

24) You have an updated RPM called screensaver-1.1.i386. rpm. You have version 1.0

installed. Using RPM, how do you view the changelog of this file to see if you should

install the update?

A. rpm -qp --changelog screensaver-1.1.i386. rpm

B. rpm --changelog screensaver-1.1.i386. rpm

C. rpm -qc screensaver-1.1.i386. rpm

D. rpm -showchangelog screensaver-1.1.i386. rpm

25) You are about to install a new program on an RPM based Linux system. Which of the

following would be the best way to accomplish this?

A. Get the source code in atarball and install from that source.

B. Get a source RPM and use rpm to install it.

C. Use rpm to install the program's binaries from an RPM package.

D. Usecpi to extract the binaries from a source RPM and use rpm to install those sources.

26) You are installing Linux on a workstation for a new employee. Which partition should be

largest?

A. /

B. /boot

C. /lib

D. /usr

27) How can you update a package only if an earlier version is currently installed on the

system?

A. rmp --update rpmname

B. rpm -U rpmname

C. rpm -F rpmname

D. rpm --force rpmname

E. rpm -u rpmname

28) You are preparing a new set of shared libraries in /usr/local/applib and you have written

and compiled some code that uses these libraries. You have already performed and

ldconfig, however the system still cannot find the shared libraries. What is most likely the

cause of this?

A. You used the wrong compiler.

B. You did not update your PATH variable.

C. You compiled the code with wrong library.

D. You forgot to put the library path inld.so.conf

29) Where can lilo place boot code?

A. The boot ROM

B. The boot RAM

C. The /boot partition

D. The MBR on a hard drive

30) Where does lilo store its boot information?

A. Boot ROM

B. Boot RAM

C. Master Boot Record

D. /boot partition

31) To what environment variable will you assign or append a value if you need to tell the

dynamic linker to look in a build directory for some of a program's shared libraries?

A. LD_LOAD_PATH

B. LD_LIB_PATH

C. LD_LIBRARY_PATH

D. LD_SHARE_PATH

E. LD_RUN_PATH

32) Which command will allow you to find a specific installed package?

A. rpm -- list rpmname

B. rpm -qvl rpmname

C. rpm rpmname

D. rpm -qv rpmname

E. rpm -f rpmname

33) You are building a server that will undergo many hardware and operating system

upgrades. The server is the file server for all users on your 100 user network. Which

directory should have its own mountpoint and/or hard drive?

A. /boot

B. /sbin

C. /home

D. /etc

34) What file is read by the program ldconfig?

A. /lib/ld.so

B. /etc/ld.so.conf

C. /etc/ld.so.cache

D. /etc/modules.conf

35) After a minor security incident you are instructed by your lead sys-admin to verify the

RPM's installed on a running system. Which command will create a complete report

which you can analyze for changes which may be security related?

Advertisement

A. rpm -Va >report

B. rpm -Qavy >report

C. rpm -Vqt --nomd5 >report

D. rpm --checkfiles >report

E. rpm -Va --nofiles >report

36) You installed a beta rpm package, but are experiencing some problems with it. How can

you remove this package?

A. rpm -qe rpmname

B. rpm -V --removerpmname

C. rpm -rrpmname

D. rpm -drpmname

E. rpm -ev rpmname

37) You see following output while trying to install an updated package: [root@example

pub]# rpm -I gthumb-2.2.0.i386.rpm package gthumb- 1.0.1.i386.rpm is already installed.

Which command will allow you to install the updated version?

A. rpm -i gthumb-2.2.0.i386.rpm

B. rpm -ivh gthumb-2.2.0.i386.rpm

C. rpm -U gthumb-2.2.0.i3S6.rpm

D. rpm -qu gthumb-2.2.0.i386.rpm

E. rpm -qiv gthumb-2.2.0.i386.rpm

38) The ________ partition is used for virtual memory.

_______________

39) Which command will create an ext3 filesystem on /dev/hda2?

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

40) Which utility would you use to change how often a filesystem check was performed over

an EXT2 filesystem (without losing any data stored on that filesystem)?

A. mod2fs

B. fsck

C. tune2fs

D. mke2fs

E. fixe2fs

41) You have just added a CD-ROM drive (/dev/hdd) to your system and have added it to

your fstab. Typically you can use which of the following commands to mount media in

that drive to /mnt/cdrom?

A. mount /dev/cdrom /mnt/cdrom

B. mount /dev/cdrom

C. mount -t cdrom/dev/cdrom /mnt/cdrom

D. mount /mnt/cdrom

E. automount /mnt/hdd /mnt/cdrom

42) The command cat /proc/dma will show you what?

A. Whether DMA is enabled

B. Which DMA channels are in use

C. Which DMA mode is in use

D. General information about DMA on the machine

43) You are formatting a single hard disk for a Linux install. What is the maximum number of

primary partitions you can create?

A. 0

B. 1

C. 2

D. 3

E. 4

F. 5

44) What is a reasonable command to uninstall a Debian package from your system?

A. dpkg -Ra pkgname

B. dpkg -R pkgname

C. dpkg -r pkgname

D. dpkg -ra pkgname

45) You want to install a new software package, but it is only available in RPM format and

you are running Debian Linux. Which of the following would help you to install it on your

system?

A. alien

B. apt-conf

C. dselect

D. cpio

46) What command will uninstall a package but leave its configuration files in case a

package is re-installed?

A. none, no command will do this

B. dpkg -s pkgname

C. dpkg -L pkgname

D. dpkg -P pkgname

E. dpkg -r pkgname

47) 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-get build-dep

B. apt-get mirror-select

C. apt-get update

D. apt-get upgrade

E. apt-get dist-upgrade

48) You want to examine the changelog for the installed package postfix. Which command

will display the changelog?

A. rpm -Vc postfix

B. rpm -qpil postfix

C. rpm --changelog postfix

D. rpm -q --changelog postfix

E. rpm -qa --changelog postfix

49) Which Debian package system command will list all partially installed packages and

suggest how to get them correctly installed?

A. dpkg -C

B. apt-get -u

C. dpkg -Dh

D. dpkg -l

E. apt-get -y

50) What is the difference between the --remove and the--purge action with the dpkg

command?

A. --remove removes the program, --purge also removes theconfig files

B. --remove only removes the program, --purge only removes theconfig files

C. --remove removes a package, --purge also removes all packages dependent on it

D. --remove removes only the package file itself, --purge removes all files related to the

package

51) Which RPM command will output the name of the package which installed the file

/etc/exports?

Advertisement

A. rpm -F /etc/exports

B. rpm -qf /etc/exports

C. rpm -Kl /etc/exports

D. rpm -qp /etc/exports

E. rpm -ql /etc/exports

52) Which file should be edited to select the network locations from which Debian installation

package files are loaded?

A. /etc/dpkg/dpkg.cfg

B. /etc/apt/apt.conf

C. /etc/apt/apt.conf.d

D. /etc/apt/sources.list

E. /etc/dpkg/dselect.cfg

53) Which command will list all the files installed from the RPM package file named, vorbis-

tools-1.1.i386. rpm?

A. rpm -qf vorbis-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.i386.rpm

E. rpm -qlp vorbis-tools-1.1.i386.rpm

54) An installed package is broken. In order to go back to the previous version of the same

package which RPM option should be used?

A. --replacefiles

B. --replacepkgs

C. --oldpackage

D. --nodeps

55) George is planning a partition scheme for a new Linux installation. Which THREE

directories should he consider for separate partitions? (Select three)

A. /etc

B. /home

C. /var

D. /lib

E. /tmp

56) Which utility can be used to convert a . rpm package to .deb package format? (Without

arguments)

_______________

57) Which environment variable you have to setup to use shared libraries that are not in the

standard search path?

_______________

58) You are formatting a single hard disk for a Linux install. What is the maximum number of

primary partitions you can create?

_______________

59) After modifying LILO's configuration file, what command should you run for the changes

to take effect?

A. kill -HUP 'pid of lilo'

B. lilo-install

C. lilo

D. reboot

60) Which TWO runlevels should never be declared as the default runlevel?

A. 0

B. 3

C. 5

D. 6

62) After modifying GRUB's configuration file, what command should you run for the

changes to take effect?

A. update-grub

B. grubinstall

C. grub

D. no action is required

63) You suspect that a new ethernet card might be conflicting with another device. Which file

should you check within the /proc tree to learn which IRQs are being used by which

kernel drives?

interrupts

64) You want to display all currently mounted file systems. Which command would you use?

(Please enter only the command without arguments or options)

mount

65) The/etc/ ________ file lists currently mounted devices.

_______________

66) ________ /dev/sda3 will create a swap area on the device/dev/sda3.

_______________

67) Which command will convert an RPM package file to a cpio archive? (Provide only the

command with no options or parameters)

_______________

68) What option, when passed to the yum command, will update the entire system? (Specify

ONLY the option name with no additional parameters)

_______________

69) Which command will disable paging and swapping on a device? (Provide only the

command with no additional options or parameters)

_______________

70) The dpkg-______ command will ask configuration QUESTION:s for a specified package,

just as if the package were being installed for the first time.

_______________

71) An administrator has issued the following command:

grub-install --root-directory=/custom-grub /dev/sda

In which directory will the new menu.lst file be found? (Provide the full directory path only

without the filename)

_______________

72) What command will print the shared libraries for the file /usr/lib/libpng12.so? (Provide the

full command with library name but without any other options or parameters)

_______________

73) In which directory must definition files be placed to add additional repositories to yum?

_______________

74) What file allow admin to adjust number of mounts after which file system will be checked

by e2fsck?

_______________

75) Do changes to the inittab file require a reboot in order to take effect?

A. No

B. Yes

76) What option can be used with the shutdown command to cancel a pending shutdown?

A. -c

B. -x

C. -a

D. -n

77) What run level represents basic multi-user?

A. 2

B. 0

Advertisement

C. 1

D. 5

78) What command be used to find the systems previous run level?

A. runlevel

B. level

C. rlevel previous

D. show previous level

79) You want to uninstall lilo. Which of the following would you do to accomplish this?

A. lilo -u

B. remove lilo

C. uninstall lilo

D. lilo -r

80) Linux is a(n) _________ operating system, meaning the source code is freely available.

A. Open sourced

B. User licensed

C. Closed source

D. Open binary

81) What run level represents multi-user?

A. 3

B. 0

C. 1

D. 5

82) After installing some new programs, each time you want to start them you get the

annoying error:

/usr/libexec/ld-elf.so.1: Shared object 'libmysqlclient.so.10' not found.

The 'locate' command confirms that you do have a file 'libmysqlclient.so.10' on your

system. What should you do? (choose the best 2 answers)

A. Copy the file libmysqlclient.so.10 to where you installed the new programs

B. Edit the file /etc/ld.so.conf

C. Run the command 'ldconfig'

D. Run the command 'ldd libmysqlclient.so.10'

83) What command would you use to list all pci devices in your system? Give only the

command, without any parameters.

_______________

84) John works as a Network Administrator for Perfect Solutions Inc. The company has

a Linux-based network. He is working as a root user on the Linux operating system. He

wants to remove a debian packet foobar from his computer and have it

maintained so that whenever he wants to install it from the stored files, he can do

so. Which of the following commands can John use to accomplish his task?

Each correct answer represents a complete solution. Choose all that apply.

A. dpkg --clear-avail

B. dpkg --remove

C. dpkg -r #

D. dpkg --purge

85) John works as a Network Administrator for Perfect Solutions Inc. The company has

a Linux-based network. John is using a dual-CPU system with an Adaptec dual-

AIC7895 SCSI controller. He wants to add new hardware to the existing Linux

operating system. However, before doing so, he wants to verify which resources are

being used by the existing devices so that he can check whether adding any new

hardware can be a cause of a hardware/software conflict or not. Which of the

following commands can John use to accomplish his task?

A. cat /proc/interrupts

B. cat /proc/partitions

C. mount | column -t

D. mount -t smbfs -o fmask=666,guest //windows_box/share /mnt/share

86) Which directory tree are you the least likely to backup or restore?

A. /tmp

B. /var

C. /proc

D. /usr

87) You want to locate the executable files that are supposed to be accessible by all of the

users. Type the path you will look into :

/bin

88) You are configuring mount points. Which of the following directories hold the mount

points?

A. /mt

B. /mntpt

C. /mount

D. /mnt

E. /mounts

89) You are arranging your files and directories. Which of the following directories is often

used to hold log files?

A. /usr

B. /tmp

C. /var

D. /root

E. /home

90) What is the device /dev/hdb6?

A. An extended partition on a SCSI disk

B. A logical partition on a SCSI disk

C. An extended partition on an IDE drive

D. A primary partition on an IDE drive

E. A logical partition on an IDE drive

91) Of the following directories, which is more important in a backup routine?

A. /var

B. /tmp

C. /usr

D. /root

E. /etc

92) Which of the following commands can be used to switch to runlevel 1?

A. init_1

B. inittab 1

C. init 1

D. level 1

E. init 6

93) What command should be run after the update lilo?

A. liloconf

B. liloupdate

C. lilo

D. update-lilo

E. lilo-update