You are on page 1of 37

101-500.examcollection.premium.exam.

60q

Number: 101-500
Passing Score: 800
Time Limit: 120 min
File Version: 1.2

Arjang institute of higher education

101-500

LPIC-1 Exam 101

Version 1.2
Exam A

QUESTION 1
FILL BLANK

Which file in the /proc filesystem lists parameters passed from the bootloader to the kernel? (Specify the file
name only without any path.)

Correct Answer: cmdline


Section: (none)
Explanation

Explanation/Reference:

QUESTION 2
Which of the following commands removes the package BigCheese and all of its
settings from a Debian based system?

A. apt-get remove --package --settings BigCheese


B. apt-get remove --purge BigCheese
C. apt-get remove --wipe BigCheese
D. apt-get remove --force BigCheese
E. apt-get remove --clean BigCheese

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 3
Which of the following commands extracts the first field from all lines of the file /etc/
passwd?

A. cut -f 0 –d " " /etc/passwd


B. cut -f 1 -d : /etc/passwd
C. grep "^.*: " /etc/passwd
D. cut -f 1 -d " " /etc/passwd
E. cut -f O -d : /etc/passwd

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 4
What is the process ID number of the init process on a System V init based system?

A. -1
B. 0
C. 1
D. It is different with each reboot
E. It is set to the current run level

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 5
Where can package repositories for yum be configured? (Choose TWO

A. In rows in the file /etc/yum/sources. list


B. In sections of the file /etc/yum. conf
C. In subdirectories of /var/lib/yum/conf/
D. In entries of the file /etc/rpm/ repos. conf
E. In files in the directory /etc/yum. repos. d/

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 6
Which command outputs the list of files installed by the RPM package file apache-
xml.rpm?

A. rpm -qp apache-xml.rpm


B. rpm -qv apache-xml.rpm
C. rpm -qpl apache-xml.rpm
D. rpm -qfl apache-xml.rpm
E. rpm -qav apache-xml.rpm

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 7
What does the command mount --bind do?

A. It makes the contents of one directory available in another directory


B. It mounts all available filesystems to the current directory
C. It mounts all user mountable filesystems to the user’s home directory
D. It mounts all file systems listed in /etc/fstab which have the option userbind set
E. It permanently mounts a regular file to a directory
Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 8
Which of the following commands can be used to write a disk image to a USB storage device?

A. dd
B. gdisk
C. mount
D. fdisk
E. cc

Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 9
Which of the following entries is valid in /etc/apt/ sources. list

A. deb http://ftp.ca.debian.org/debian testing main


B. main url=http://ftp.ca.debian.org/debian distro=testing
C. @import http://ftp.ca.debian.org/debian/testing/main/repo.conf
D. deb://testing@ftp.ca.debian.org:main
E. repo http://ftp.ca.debian.org/debian/testing/main

Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 10
Which apt subcommand refreshes the information about available packages in the
configured package repositories? (Specify ONL V the sub command without any path
or parameters.)
Correct Answer: update
Section: (none)
Explanation

Explanation/Reference:

QUESTION 11
Which of the following commands generate hash sums? (Choose TWO correct answers.)
A. bz2sum
B. md5sum
C. sha256sum
D. xzsum
E. bcsum

Correct Answer: BC
Section: (none)
Explanation

Explanation/Reference:

QUESTION 12
Which of the following commands updates the linker cache of shared libraries?

A. mkcache
B. ldconfig
C. mkldconfig
D. soconfig
E. lddconfig

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 13
Which of the following commands runs program with the environment variable FOO set to BAR?

A. set FOO=BAR | program


B. runenv -e 'FOO=BAR' program
C. FOO=BAR &| program
D. export -c program FOO=BAR
E. env FOO=BAR program

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 14
Which of the following commands does NOT update the modification timestamp on
the file /tmp/myfile. txt?

A. sed -ie "s/1/2/" /tmp/myfile.txt


B. echo "Hello" >/tmp/myfile.txt
C. file /tmp/myfile.txt
D. echo -n "Hello" >>/tmp/myfile.txt
E. touch /tmp/myfile.txt

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 15
Which of the following statements are true about the boot sequence of a PC using a BIOS? (Choose two.)

A. Some parts of the boot process can be configured from the BIOS
B. Linux does not require the assistance of the BIOS to boot a computer
C. The BIOS boot process starts only if secondary storage, such as the hard disk, is functional
D. The BIOS initiates the boot process after turning the computer on
E. The BIOS is started by loading hardware drivers from secondary storage, such as the hard disk

Correct Answer: AD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 16
What is true about application containers, such as Docker containers?

A. They keep all their data on a ramdisk which consumes memory for the container's base
file system
B. They only contain a statically linked binary and have no other file system content
C. They consume a significant amount of time to install the application at each container
start
D. They use ephemeral storage only and cannot store data on a persistent storage
E. They start an application directly without using an init system such as systemd

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 17
Which information is contained in the output of uname -a? (Choose TWO correct answers.)

A. The number of user sessions


B. The hostname of the local system
C. The version of the running kernel
D. The uptime of the local system
E. The name of current user shell.

Correct Answer: BC
Section: (none)
Explanation

Explanation/Reference:

QUESTION 18
Which of the following commands extracts the contents of foo. tar into the directory /
tmp/files/?

A. tar -xf foo.tar -p /tmp/files/


B. tar -xf /tmp/files/ -C foo.tar
C. tar -xf foo.tar /tmp/files/
D. tar -xf foo.tar -C /tmp/files/
E. tar -cf foo.tar -X /tmp/files/

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 19
Which command displays the manual page chown ( 2) when multiple chown manual pages
exist in other categories? (Specify the command without any path but INCLUDING ALL
REQUIRED PARAMETERS.)

Correct Answer: man 2 chown


Section: (none)
Explanation

Explanation/Reference:

QUESTION 20
Which option of e2fsck fixes all errors found in an EXT4 file system without user interaction? (Specify ONLY
the option, without any values or parameters.)

Correct Answer: -f
Section: (none)
Explanation

Explanation/Reference:

QUESTION 21
Which of the following commands install the package BigCheese. rpm on a Red Hat
based system? (Choose TWO correct answers.)

A. dpkg -i BigCheese.rpm
B. rpm --add BigCheese.rpm
C. apt-get rpminstall BigCheese.rpm
D. rpm -i BigCheese.rpm
E. rpm --install BigCheese.rpm

Correct Answer: DE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 22
What is the effect of the key combination ctrl and R in the Bash shell?

A. It moves the cursor to the first space character after the command.
B. It opens the man page of the current command.
C. It displays information on the usage of the current command.
D. It copies the current command to the clipboard
E. It searches the shell history for a previously executed command

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 23
FILL BLANK

Which program updates the database that is used by the locate command? (Specify ONLY the command
without any path or parameters).

Correct Answer: updatedb


Section: (none)
Explanation

Explanation/Reference:

QUESTION 24
Which daemon handles power management events on a Linux system?

A. acpid
B. batteryd
C. pwrmgntd
D. psd
E. inetd

Correct Answer: A
Section: (none)
Explanation
Explanation/Reference:

QUESTION 25
After successfully creating a hard link called bar to the ordinary file foo, foo is deleted from the file system.
Which of the following describes the resulting situation?

A. foo and bar are removed both


B. foo is removed. bar still exist but is unusable.
C. foo is removed while bar remains accessible
D. Both foo and bar remain accessible
E. The user is prompted whether bar should be removed in addition to foo

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 26
On a UEFI system, from where does the firmware load the bootloader?

A. From the sectors 512 to 2047 of the boot disk.


B. From a file on the root partition's /boot/ directory.
C. From a file on the EFI System Partition
D. From the master boot record of the boot disk.
E. From the partition holding the boot flag in the GPT.

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 27
Which of the following commands reboots the system when using System V init?
(Choose TWO correct answers.)

A. shutdown -r "reboot"
B. shutdown -r now
C. telinit 0
D. telinit 6
E. shutdown –k now "reboot"

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 28
What is true for entries in /etc/fstab and systemd mount units? (Choose TWO correct
answers.)

A. Either /etc/fstab or systemd mount units can be used, but not both.
B. Each entry in / etc/ fstab requires a corresponding unit file in /etc/systemd/fs
C. Mounts in /etc/fstab are ignored by systemd
D. systemd automatically creates mount units for file systems listed in /etc/fstab
E. Special options for /etc/fstab can control systemd mount units relating to the file system.

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 29
In the vi editor, which of the following commands copies the current line into the vi buffer?

A. C
B. cc
C. le
D. ly
E. yy

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 30
Which of the following options must be passed to a file system's entry in /etc/fstab in order to mount the file
system without root privileges?

A. auto
B. norestrict
C. user
D. noauto
E. anon

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 31
In order to display all currently mounted filesystems, which of the following commands could be used? (Choose
two.)
A. cat /proc/self/mounts
B. free
C. lsmounts
D. mount
E. cat /proc/filesystems

Correct Answer: AD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 32
What is true about the default permissions of the /tmp/ directory?

A. /tmp/ has the NoExec bit set to prevent the execution of binaries in the directory
B. / tmp / has the Sticky bit set which allows only root and the respective owner to deletefiles
or directories
C. /tmp/ has the TempFS bit set which causes the deletion of obsolete files after a specific
amount of time
D. /tmp/ has SetRoot bit set which limits the creation of new files to the user root
E. /tmp/ has the SetMem bit set which keeps the directory's contents in memory.

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 33
Which type of file system is created by mkfs when it is executed with the block device name only and without
any additional parameters?

A. XFS
B. VFAT
C. ext2
D. ext3
E. ext4

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 34
Which chown command changes the ownership to dave and the group to staff on a file named data.txt?

A. chown dave/staff data.txt


B. chown –u dave –g staff data.txt
C. chown --user dave --group staff data.txt
D. chown dave+staff data.txt
E. chown dave:staff data.txt

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 35
Which umask value ensures that new directories can be read, written and listed by their owning user, read and
listed by their owning group and are not accessible at all for everyone else?

A. 0750
B. 0027
C. 0036
D. 7640
E. 0029

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 36
Which of the following commands changes the number of days before the ext3 filesystem on /dev/sda1 has to
run through a full filesystem check while booting?

A. tune2fs –d 200 /dev/sda1


B. tune2fs –i 200 /dev/sda1
C. tune2fs –c 200 /dev/sda1
D. tune2fs –n 200 /dev/sda1
E. tune2fs --days 200 /dev/sda1

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 37
Which is the default percentage of reserved space for the root user on new ext4 filesystems?

A. 10%
B. 3%
C. 15%
D. 0%
E. 5%
Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 38
After deleting a line in vi using dd, how can the removed line be inserted at the current cursor position?

A. By using the vi command udel.


B. By using the vi command p
C. By using the vi command : p.
D. By using the keystroke Ctrl+v.
E. By using the vi command D

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 39
In compliance with the FHS, in which of the directories are man pages found?

A. /opt/man/
B. /usr/doc/
C. /usr/share/man/
D. /var/pkg/man
E. /var/man/

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 40
Which of the following tools can move processes to the background and reattach them to a
terminal later? (Choose TWO correct answers.)

A. watch
B. wait
C. nohup
D. screen
E. tmux

Correct Answer: CE
Section: (none)
Explanation

Explanation/Reference:
QUESTION 41
Consider the following output from the command ls –i:

How would a new file named c.txt be created with the same inode number as a.txt (Inode 525385)?

A. ln –h a.txt c.txt
B. ln c.txt a.txt
C. ln a.txt c.txt
D. ln –f c.txt a.txt
E. ln –i 525385 c.txt

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 42
Consider the following directory:

drwxrwxr-x 2 root sales 4096 Jan 1 15:21 sales

Which command ensures new files created within the directory sales are owned by the group sales?
(Choose two.)

A. chmod g+s sales


B. setpol –R newgroup=sales sales
C. chgrp –p sales sales
D. chown --persistent *.sales sales
E. chmod 2775 sales

Correct Answer: CE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 43
What is the meaning of the ? metacharacter within an extended regular expression?

A. Match the preceding qualifier one or more times


B. Match the preceding qualifier zero or more times.
C. Match any single alphanumeric character
D. Match a literal ? character.
E. Match the preceding qualifier zero or one times

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 44
FILL BLANK

Which command displays the current disk space usage for all mounted file systems? (Specify ONLY the
command without any path or parameters.)

Correct Answer: du
Section: (none)
Explanation

Explanation/Reference:

QUESTION 45
When considering the use of hard links, what are valid reasons not to use hard links?

A. Hard links are not available on all Linux systems because traditional filesystems, such as ext4, do not
support them
B. Each hard link has individual ownership, permissions and ACLs which can lead to unintended disclosure of
file content
C. Hard links are specific to one filesystem and cannot point to files on another filesystem
D. If users other than root should be able to create hard links, suln has to be installed and configured
E. When a hard linked file is changed, a copy of the file is created and consumes additional space

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 46
Which of the following commands locates all files of size greater than 1024 KiB whose file
name ends in .o?

A. find / -size +1024 -name '*.o'


B. find / +size 1024k -name '* .o'
C. find / -size +1024k -name '* .0 '
D. find / -size >1048k -name '* .o'
E. find / -minsize 1024k -name '* .0

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 47
Which of the following statements is correct regarding the command foo 1> bar if the
noclobber shell option is not set?

A. The standard output from the command foo is appended to the file bar.
B. The command foo receives its standard input from the standard output of the command
bar
C. The command foo receives its standard input from the file bar.
D. The standard output from the command foo overwrites the file bar if it already exists.
E. The standard error from the command foo is saved to the file bar

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 48
In which of the following locations is the Master Boot Record (MBR) stored?

A. On the boot partition of the operating system.


B. On every file system partition.
C. In a writable area of the firmware of the hard disk
D. On all partitions which are flagged as bootable.
E. On the hard disk's first sector

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 49
Which systemd command uses subcommands such as start or stop to control
services?

A. sysctl
B. systemctl
C. rund
D. systemd
E. serviced

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 50
A system is using the following partition table and filesystem setup

Which of the following statements are true regarding the UUIDs shown in the output above? (Choose TWO
correct answers.)

A. For each file system, the Linux kernel provides additional information within a directory in /proc/filesystems/
named by the file systems's UUID.
B. The UUIDs are only used by the BIOS/ UEFI firmware and cannot be used to identify the partitions in Linux.
C. The UUIDs are not persistent across reboots, as they are regenerated each time the system boots
D. Using the UUIDs as identifiers when mounting file systems is recommended, because UUIDs are persistent
after the filesystem's creation.
E. The directory /dev/disk/by-uuid/ contains symbolic links to the partition's devices named by their UUIDs.

Correct Answer: DE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 51
When planning a partition scheme, which of the following directories might be stored on a dedicated hard disk
partition? (Choose THREE correct answers.)

A. /etc
B. /var
C. /proc
D. /home
E. /opt

Correct Answer: BDE


Section: (none)
Explanation

Explanation/Reference:

QUESTION 52
Which of the following is a definition of a mount point

A. A hard link to another directory


B. A device file representing any block device
C. A device file representing a physical disk
D. A directory in the virtual file system /sys/mounts
E. A directory through which a storage device is accessed

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 53
In the vi editor, which symbol starts the search for a string? (Specify ONLY the single character symbol
without any parameters.)

Correct Answer: /
Section: (none)
Explanation

Explanation/Reference:

QUESTION 54
Which of the following file systems can be used on Linux root partitions? (Choose TWO correct answers.)

A. NTFS
B. ext3
C. VFAT
D. XFS
E. swap

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 55
Which of the following commands can be used to locate programs, their corresponding man pages and
configuration files?

A. dirname
B. whereis
C. basename
D. query
E. which

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 56
The command find /grub/grub. conf, issued in the GRUB boot loader shell, leads to the
following output (hdl , 2) (hd2 , 1) Which of the following statements is true about this system?

A. Each of the listed devices should contain a grub. conf file but it is missing on both
devices.
B. The listed devices are not writable as indicated by the brackets
C. There are exactly two hard drives installed on this machine.
D. The computer uses a non-standard version of the find command.
E. The computer has two boot partitions which both contain a GRUB configuration file

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 57
Which of the following statements are true regarding file system inodes? (Choose TWO correct answers.)

A. A single inode can contain information on multiple files


B. Each new file or directory consumes one free inode
C. lnodes are only used on ext file systems, such as ext4.
D. lnodes store journaling information until the next reboot
E. The usage of inodes can be displayed by using df -i

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 58
Which redirection operator sends all error messages to a file without changing the
destination of the standard output? (Specify ONLY the redirection operator without any
commands or files.)
Correct Answer: 2>
Section: (none)
Explanation

Explanation/Reference:

QUESTION 59
What command turns the output of one command into arguments for the invocation of
another command? (Specify ONLY the command without any path or parameters.)
Correct Answer: xargs
Section: (none)
Explanation

Explanation/Reference:

QUESTION 60
Which of the following configurations can be achieved using umask ?
A. Ensure that new files cannot be moved from their initial directories.
B. Prevent an executable script from running any other commands
C. Exclude a list of specific users from accessing a new file
D. Prevent all regular users, except the owner, from accessing a new file
E. Avoid the creation of files of a specific type, such as PDF

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 61
Consider the following output from the command ls -1i:
817457 -rw-r--r-- 2 bob staff 0 Feb 27 15:51 a.txt
817457 -rw-r--r-- 2 bob staff 0 Feb 27 15:51 b.txt
What happens when the command chmod 600 b. txt is executed?

A. The hard links break and two separate files with individual permissions are created.
B. An error is displayed and chmod has to be run with - f in order to change both files
C. b. txt stays unchanged until the permissions of a. txt are changed to 600 as well.
D. b. txt has the permissions 600 while a. txt remains unchanged
E. The permissions of both files, a. txt and b. txt, are changed to 600

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 62
Which of the following commands displays both the priority and niceness of a running process?

A. ps -pn
B. ps -p
C. ps -t n, t
D. Ps -t nice , pri
E. ps -Al

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 63
Which of the following commands sends output from the program myapp to both standard
output and the file filel. log?
A. cat < myapp | cat> filel.log
B. myapp 0>&1 | cat> filel.log
C. myapp | cat> filel.log
D. . tee myapp filel.log
E. myapp | tee filel.log

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 64
According to the Filesystem Hierarchy Standard (FHS), what files are found in the /etc/
directory?

A. Optional applications binaries.


B. Binary files needed to boot the system
C. Shared library files needed to run system services.
D. User specific personal files and directories.
E. System configuration files

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 65
What is the first program the Linux kernel starts at boot time when using System V init?

A. /lib/init.so
B. /proc/sys/kernel/init
C. /etc/rc.d/rcinit
D. /sbin/init
E. /boot/init

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 66
A faulty kernel module is causing issues with a network interface card. Which of the following actions ensures
that this module is not loaded automatically when the system boots?

A. Using lsmod --remove --autoclean without specifying the name of a specific module
B. Using modinfo –k followed by the name of the offending module
C. Using modprobe –r followed by the name of the offending module
D. Adding a blacklist line including the name of the offending module to the file /etc/modprobe.d/
blacklist.conf
E. Deleting the kernel module’s directory from the file system and recompiling the kernel, including its modules

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 67
Which of the following is true when a file system, which is neither listed in /etc/fstab nor known to system,
is mounted manually?

A. systemd ignores any manual mounts which are not done using the systemctl mount command
B. The command systemctl mountsync can be used to create a mount unit based on the existing mount
C. systemd automatically generates a mount unit and monitors the mount point without changing it
D. Unless a systemd mount unit is created, systemd unmounts the file system after a short period of time
E. systemctl unmount must be used to remove the mount because system opens a file descriptor on the
mount point

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 68
Which signal is sent by the kill command by default?

A. SIGHUP(1)
B. SIGQUIT(3)
C. SIGKILL(9)
D. SIGTERM(15)
E. SIGSTOP(19)

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 69
Which of the following invocations runs the command foo as a background process?

A. & foo
B. fg foo
C. nohup foo
D. bg foo
E. foo &

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 70
Which command displays a sortable, frequently updated list of running processes? (Specify ONLY the
command without any path or parameters.)

Correct Answer: top


Section: (none)
Explanation

Explanation/Reference:

QUESTION 71
Which of the following commands runs the program foo with a lower than normal priority?

A. nice -n -10 foo


B. nice -n 0 foo
C. nice -n +19 foo
D. renice -n -10 foo
E. renice -n +19 foo

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 72
Which of the following commands installs GRUB 2 into the master boot record on the third hard disk?

A. grub2 install /dev/sdc


B. grub-mkrescue /dev/sdc
C. grub-mbrinstall /dev/sdc
D. grub-setup /dev/sdc
E. grub-install /dev/sdc

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 73
Which of the following commands installs all packages with a name ending with the string foo?
A. zypper get “*foo”
B. zypper update “foo?”
C. zypper force “foo*”
D. zypper install “*foo”
E. zypper add “.*foo”

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 74
Which of the following commands prints only the lines that do not end with a / in the file foo?

A. grep -v '/ $ ' foo


B. grep ' / # ' foo
C. grep -r ' / $ ' foo
D. grep -v ' / # ' foo
E. grep ' / $ ' foo

Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 75
Which of the following regular expressions match all of the following lines? (Choose TWO correct answers.)
cheese
pease
please

A. /{a,e}se$/
B. /a, ese$/
C. /[ae]se$/
D. I (a-e) se$/
E. /[a | e]se$/

Correct Answer: CD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 76
What is true regarding UEFI firmware? (Choose two.)

A. It can read and interpret partition tables


B. It can use and read certain file systems
C. It stores its entire configuration on the /boot/ partition
D. It is stored in a special area within the GPT metadata
E. It is loaded from a fixed boot disk position

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 77
What is true regarding the configuration of yum? (Choose two.)

A. Changes to the repository configuration become active after running yum confupdate
B. Changes to the yum configuration become active after restarting the yumd service
C. The configuration of package repositories can be divided into multiple files
D. Repository configurations can include variables such as $basearch or $releasever
E. In case /etc/yum.repos.d/ contains files, /etc/yum.conf is ignored

Correct Answer: CD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 78
When is the content of the kernel ring buffer reset? (Choose two.)

A. When the ring buffer is explicitly reset using the command dmesg --clear
B. When the ring buffer is read using dmesg without any additional parameters
C. When a configurable amount of time, 15 minutes by default, has passed
D. When the kernel loads a previously unloaded kernel module
E. When the system is shut down or rebooted

Correct Answer: AE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 79
What is contained on the EFI System Partition?

A. The Linux root file system


B. The first stage boot loader
C. The default swap space file
D. The Linux default shell binaries
E. The user home directories

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 80
Which of the following directories on a 64 bit Linux system typically contain shared libraries? (Choose two.)

A. ~/.lib64/
B. /usr/lib64/
C. /var/lib64/
D. /lib64/
E. /opt/lib64/

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 81
Which of the following files exist in a standard GRUB 2 installation? (Choose two.)

A. /boot/grub/stages/stage0
B. /boot/grub/i386-pc/lvm.mod
C. /boot/grub/fstab
D. /boot/grub/grub.cfg
E. /boot/grub/linux/vmlinuz

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 82
Which of the following commands lists the dependencies of the RPM package file foo.rpm?

A. rpm –qpR foo.rpm


B. rpm –dep foo
C. rpm –ld foo.rpm
D. rpm –R foo.rpm
E. rpm –pD foo

Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 83
Which of the following properties of a Linux system should be changed when a virtual machine is cloned?
(Choose two.)

A. The partitioning scheme


B. The file system
C. The D-Bus Machine ID
D. The permissions of /root/
E. The SSH host keys

Correct Answer: CE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 84
Which of the following are valid stream redirection operators within Bash? (Choose two.)

A. <
B. #>
C. %>
D. >>>
E. 2>&1

Correct Answer: AE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 85
Which of the following partition types is used for Linux swap spaces when partitioning hard disk drives?

A. 7
B. 82
C. 83
D. 8e
E. fd

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 86
A Debian package creates several files during its installation. Which of the following commands searches for
packages owning the file /etc/debian_version?

A. apt-get search /etc/debian_version


B. apt –r /etc/debian_version
C. find /etc/debian_version -dpkg
D. dpkg –S /etc/debian_version
E. apt-file /etc/debian_version

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 87
Which of the following apt-get subcommands installs the newest versions of all currently installed packages?

A. auto-update
B. dist-upgrade
C. full-upgrade
D. install
E. update

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 88
Which command uninstalls a package but keeps its configuration files in case the package is re-installed?

A. dpkg –s pkgname
B. dpkg –L pkgname
C. dpkg –P pkgname
D. dpkg –v pkgname
E. dpkg –r pkgname

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 89
Which of the following commands changes all CR-LF line breaks in the text file userlist.txt to Linux
standard LF line breaks and stores the result in newlist.txt?

A. tr –d ‘\r’ < userlist.txt > newlist.txt


B. tr –c ‘\n\r’ ‘’ <newlist.txt> userlist.txt
C. tr ‘\r\n’ ‘’ <userlist.txt> newlist.txt
D. tr ‘\r’ ‘\n’ userlist.txt newlist.txt
E. tr –s ‘/^M/^J/’ userlist.txt newlist.txt

Correct Answer: A
Section: (none)
Explanation
Explanation/Reference:

QUESTION 90
What is the maximum niceness value that a regular user can assign to a process with the nice command when
executing a new process?

A. 9
B. 15
C. 19
D. 49
E. 99

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 91
Which of the following commands list all files and directories within the /tmp/ directory and its subdirectories
which are owned by the user root? (Choose two.)

A. find /tmp –user root -print


B. find –path /tmp –uid root
C. find /tmp –uid root -print
D. find /tmp –user root
E. find –path /tmp –user root -print

Correct Answer: AD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 92
Which command must be entered before exiting vi to save the current file as filea.txt?

A. %s filea.txt
B. %w filea.txt
C. :save filea.txt
D. :w filea.txt
E. :s filea.txt

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 93
Which of the following vi commands deletes two lines, the current and the following line?

A. d2
B. 2d
C. 2dd
D. dd2
E. de12

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 94
Which of the following commands displays the path to the executable file that would be executed when the
command foo is invoked?

A. lsattr foo
B. apropos foo
C. locate foo
D. whatis foo
E. which foo

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 95
When redirecting the output of find to the xargs command, what option to find is useful if the filenames
contain spaces?

A. –rep-space
B. -printnul
C. -nospace
D. –ignore-space
E. –print0

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 96
The command dbmaint & was used to run dbmaint in the background. However, dbmaint is terminated
after logging out of the system. Which alternative dbmaint invocation lets dbmaint continue to run even when
the user running the program logs out?

A. job –b dmaint
B. dbmaint &>/dev/pts/null
C. nohup dbmaint &
D. bg dbmaint
E. wait dbmaint

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 97
Which of the following commands can be used to determine how long the system has been running? (Choose
two.)

A. uptime
B. up
C. time --up
D. uname –u
E. top

Correct Answer: AE
Section: (none)
Explanation

Explanation/Reference:

QUESTION 98
From a Bash shell, which of the following commands directly execute the instructions from the file /usr/
local/bin/runme.sh without starting a subshell? (Choose two.)

A. source /usr/local/bin/runme.sh
B. /usr/local/bin/runme.sh
C. /bin/bash /usr/local/bin/runme.sh
D. . /usr/local/bin/runme.sh
E. run /usr/local/bin/runme.sh

Correct Answer: AD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 99
FILL BLANK

Which program runs a command in specific intervals and refreshes the display of the program’s output?
(Specify ONLY the command without any path or parameters.)

Correct Answer: watch


Section: (none)
Explanation
Explanation/Reference:

QUESTION 100
Immediately after deleting 3 lines of text in vi and moving the cursor to a different line, which single character
command will insert the deleted content below the current line?

A. i (lowercase)
B. p (lowercase)
C. P (uppercase)
D. U (uppercase)
E. u (lowercase)

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 101
Given the following input stream:
txt1.txt
atxt.txt
txtB.txt
Which of the following regular expressions turns this input stream into the following output stream?
txt1.bak.txt
atxt.bak.txt
txtB.bak.txt

A. s/^.txt/.bak/
B. s/txt/bak.txt/
C. s/txt$/bak.txt/
D. s/^txt$/.bak^/
E. s/[.txt]/.bak$1/

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 102
Which of the following signals is sent to a process when the key combination Ctrl+C is pressed on the
keyboard?

A. SIGTERM
B. SIGCONT
C. SIGSTOP
D. SIGKILL
E. SIGINT

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 103
What output will be displayed when the user fred executes the following command?
echo ‘fred $USER’

A. fred fred
B. fred /home/fred/
C. ‘fred $USER’
D. fred $USER
E. ‘fred fred’

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 104
Which of the following regular expressions represents a single upper-case letter?

A. :UPPER:
B. [A-Z]
C. !a-z
D. %C
E. {AZ}

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 105
Given a log file loga.log with timestamps of the format DD/MM/YYYY:hh:mm:ss, which command filters out
all log entries in the time period between 8:00 am and 8:59 am?

A. grep –E ‘:08:[09]+:[09]+’ loga.log


B. grep –E ‘:08:[00]+’ loga.log
C. grep –E loga.log ‘:08:[0-9]+:[0-9]+’
D. grep loga.log ‘:08:[0-9]:[0-9]’
E. grep –E ‘:08:[0-9]+:[0-9]+’ loga.log

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:
QUESTION 106
What is true regarding the command
ls > files
if files does not exist?

A. The output of ls is printed to the terminal


B. files is created and contains the output of ls
C. An error message is shown and ls is not executed
D. The command files is executed and receives the output of ls
E. Any output of ls is discarded

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 107
Which Linux kernel parameter suppresses most messages the kernel prints on startup?

A. verbose=false
B. dmesg
C. > /dev/null
D. nmesg
E. quiet

Correct Answer: E
Section: (none)
Explanation

Explanation/Reference:

QUESTION 108
FILL BLANK

Which command is used to start another command with a given nice level? (Specify ONLY the command
without any path or parameters.)

Correct Answer: nice


Section: (none)
Explanation

Explanation/Reference:

QUESTION 109
Which of the following files, located in a user’s home directory, contains the Bash history?

A. .bashrc_history
B. .bash_histfile
C. .history
D. .bash_history
E. .history_bash
Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 110
Which wildcards will match the following filenames? (Choose two.)
ttyS0
ttyS1
ttyS2

A. ttyS[1-5]
B. tty?[0-5]
C. tty*2
D. tty[A-Z][012]
E. tty[Ss][02]

Correct Answer: BD
Section: (none)
Explanation

Explanation/Reference:

QUESTION 111
Which of the following commands redirects the output of ls to standard error?

A. ls >-1
B. ls <<ERR
C. ls >&2
D. ls >>2
E. ls |error

Correct Answer: C
Section: (none)
Explanation

Explanation/Reference:

QUESTION 112
Which of the following commands displays the contents of a gzip compressed tar archive?

A. gzip archive.tgz | tar xvf -


B. tar –fzt archive.tgz
C. gzip –d archive.tgz | tar tvf -
D. tar cf archive.tgz
E. tar ztf archive.tgz

Correct Answer: E
Section: (none)
Explanation
Explanation/Reference:

QUESTION 113
Which of the following commands displays the output of the foo command on the screen and also writes it to a
file called /tmp/foodata?

A. foo | less /tmp/foodata


B. foo | cp /tmp/foodata
C. foo > /tmp/foodata
D. foo | tee /tmp/foodata
E. foo > stdout >> /tmp/foodata

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

QUESTION 114
Which of the following commands prints a list of usernames (first column) and their primary group (fourth
column) from the /etc/passwd file?

A. fmt –f 1,4 /etc/passwd


B. cut –d : -f 1,4 /etc/passwd
C. sort –t : -k 1,4 /etc/passwd
D. paste –f 1,4 /etc/passwd
E. split –c 1,4 /etc/passwd

Correct Answer: B
Section: (none)
Explanation

Explanation/Reference:

QUESTION 115
What file contains configuration settings that are passed to kernel modules when they are
loaded? (Specify the full path to the file.)
Correct Answer: /etc/modprobe
Section: (none)
Explanation

Explanation/Reference:
/etc/modprobe
QUESTION 116
A new kernel boot parameter has been added to the bootloader configuration.
What can be done to confirm that the parameter was passed to the kernel after rebooting
the system?

A. Check if the new parameter is listed in the file /proc/cmdline


B. Check if the new parameter is listed in the file /sys/f s/kerne1/bootopts
C. Check if the new parameter is represented by an own file in /dev/kernel/opt/.
D. Check if the new parameter is present in the output of the command kernel -p
E. Check if the new parameter is present in the output of the command sysctl -b kernel.*.

Correct Answer: A
Section: (none)
Explanation

Explanation/Reference:

QUESTION 117
During a system boot cycle, what program is executed after the BIOS completes its tasks?

A. The Linux kernel


B. The inetd program
C. The ini t program
D. The bootloader
E. The linuxrc program

Correct Answer: D
Section: (none)
Explanation

Explanation/Reference:

You might also like