cueFlash

Glossary of LPIC 102

Start Studying! Add Cards ↓

Created by welcome47

Which of the following commands is used to add a new user, and is available across different linux distributions. Select the most appropriate answer:

user --add
add --user
newuser
usernew
useradd





the answer is useradd.
Which of the following lines at the top of a file will make it an executable shell script (assuming file permissions are correct)? Choose the most appropriate answer.

#/bin/bash
!#/bin/bash
#!/bin/bash
#!bash
!#bash





The answer is #!/bin/bash.
What command, including options, will take the system time and store in it in the hardware clock?



The correct answer is hwclock --systohc or hwclock -w
Which of the following commands will add the user \"stewart\" to the group \"wheel\"? Select the most appropriate answer.

gpasswd -a wheel stewart
gpasswd -a stewart wheel
groupadd stewart wheel
groupadd wheel stewart




The correct answer is gpasswd -a stewart wheel. The groupadd command is used to create a new group.
Which of the following is a valid entry in the /etc/passwd file? The username is john and his real name is John Smith. Please choose the most appropriate answer:

john:x:502:502:John Smith:/home/john:/bin/bash
502:502:john:x:John Smith:/bin/bash:


john:x:502:502:John Smith:/home/john:/bin/bash
Which of the following commands will create a new group called \"trainers\"? Select the most appropriate answer.

addgroup trainers
add --group trainers
groupadd trainers
newgroup trainers
newgrp trainers





The correct answer is groupadd trainers. The newgrp command will change the current group during the session, not create a new one. The rest are not valid commands.
According to RFC 1918 a number of address ranges are reserved for private internets. Which of the following addresses are not in the private ranges? Select all that apply.

10.254.254.3
32.71.4.12
172.1.0.3
172.31.23.123
192.168.3.4





The answer is 32.71.4.12 and 172.1.0.3.
The reserved ranges are:
10.0.0.0 - 10.255.255.255 (10/8 prefix)
172.16.0.0 - 172.31.255.255 (172.16/12 prefix)
192.168.0.0 - 192.168.255.255 (192.168/16 prefix)



If you connect to tcp port 21 what service would you normally be using?

ftp
telnet
ssh
chargen
smtp





The answer is ftp. The port numbers of the other services are:
telnet = 23
ssh = 22
chargen = 19
smtp = 25



What command is used to reload the /etc/inittab file after it has been updated? Choose the most appropriate answer:

/sbin/init q
/sbin/init r
/sbin/init s
/sbin/init 6




The correct command is /sbin/init q. The r option is not a valid option for the init command. The s option will change to single user mode, and the 6 option will reboot the system. The option q is the most appropriate as it reloads the configuration file without rebooting the server.
What is the correct order for the processes running during startup?
The answer is kernel loaded; init; rc.sysinit; runlevel scripts.
Which line below could be a valid line in the /etc/group file? The users: john, stewart and fred should all be members of the finance group.

finance:x:503:john,stewart,fred
503:finance:x:john,stewart,fred


The correct answer is finance:x:503:john,stewart,fred.
What is the file on a linux machine that provides the list of known tcp/udp ports along with their respective services? Include the full path.
The answer is /etc/services.
Fill in the blank with the options that would be used with the host command to view the mail entries for penguintutor.com.

host -___ penguintutor.com

The correct answer is: host -t MX penguintutor.com
Which of the following is a valid entry in the /etc/passwd file? The username is john and his real name is John Smith.

502:502:john:x:John Smith:/bin/bash:/home/john
john:x:502:502:John Smith:/home/john:/bin/bash


The correct answer is john:x:502:502:John Smith:/home/john:/bin/bash.
Which of the following addresses are by default in a class B network? Select all that apply.

126.3.43.3
128.1.3.7
142.35.12.0
190.3.78.3
191.37.2.10
193.24.2.43
194.1.1.2







The following addresses are class B network addresses:
128.1.3.7
142.35.12.0
190.3.78.3
191.37.2.10



When using private key authentication using ssh, what permission should the private keys have in /etc/ssh and ~/.ssh? Provide the octal file permission number as used by chmod (digits only).
The answer is 600.
Which of the following options can be added to an SQL select statement to sort the results?

SORT BY
LIST BY
ORDER BY
SORTED




ORDER BY is the correct option for sorting the rows.
What is the recommended alternative to cron if the system is not left running continuously?
The alternative to cron is anacron. This command has the ability to run events after their scheduled time if the system was not running when it was due.
Which of the following is valid syntax for the route command?

/sbin/route add -net 192.168.5.0 gw 192.168.1.1 netmask 255.255.255.0 dev eth0
/sbin/route add -net 192.168.5.0 -gw 192.168.1.1 -netmask 255.255.255.0 -dev eth0


The correct answer is /sbin/route add -net 192.168.5.0 gw 192.168.1.1 netmask 255.255.255.0 dev eth0. All the other entries give a syntax error.
Which is the CIDR netmask /27 in quaded dot form?
The answer is 255.255.255.224.

Which command can be used to identify the routing path through the network to a destination address? Choose the most appropriate answer.

ping
traceroute
ifconfig
nslookup





The answer is traceroute. The ping command will verify if a host can be reached, but not identify the path used. The ifconfig command shows the interfaces of the computer, and the nslookup command is used to test name resolution.
Which of the following is the configuration file used to determine who can use the sudo command?

/etc/sudo.cfg
/etc/sudoers
/etc/sudo/sodo.cfg
/etc/sudo/users




/etc/sudoers
A host has the IP address 192.168.2.27 and a netmask of 255.255.255.0. What is the broadcast address of that network?
The answer is 192.168.2.255.
What command in a script would print on the screen the first variable past to that script?
The answer is /usr/bin/echo $1.
Which of the following commands will show any pending at jobs? Select all that apply.

at -l
aq -q
atq
atl
at --list





The correct answers are at -l and atq
If you want an interactive input from the user into a shell script what command can be used to get user input and store in in the $REPLY variable?
The answer is read.
What is the port number normally used for a telnet connection?
The answer is 23.
A host has the IP address 192.168.1.12 and a netmask of 255.255.255.0. What is the address of the network?
The answer is 192.168.1.0.
class A networks are followed by a /__?
/8
class B networks are followed by a /__?
/16
class C networks are followed by a /__?
/24
What is the Class A Network Address Range?
1.0.0.0 - 127.255.255.255
What is the Class B Network Address Range?
128.0.0.0 - 191.255.255.255
What is the Class C Network Range?
192.0.0.0 - 223.255.255.255
What is the Class D Network Range?
224.0.0.0 - 239.255.255.255
What is the Class E Network Range?
240.0.0.0 - 255.255.255.255
What are the Class A Reserved Private Addresses?
10.0.0.0 - 10.255.255.255
What are the Class B Reserved Private Addresses?
172.16.0.0 - 172.31.255.255
What are the Class C Reserved Private Addresses?
192.168.0.0 - 192.168.255.255
You need to use tcpwrappers so that only address 192.168.1.7 can access all the services. Assuming you\'ve added the appropriate entry to /etc/hosts.allow what would you need to put in /etc/hosts.deny? (or leave blank if you would not use hosts.deny)
The answer is
ALL: ALL
What configuration file is used to determine the addresses of the DNS servers to use on a client workstation? Include the full path.
The correct answer is /etc/resolv.conf.
What function does gdm / kdm perform on a Gnome / KDE system?

Login Screen
Replacement for X Windows
Defines what application windows look like
Provide 3D effects when changing virtual screen




They provide the graphical user login screen. They are called the Gnome Display Manager and KDE Display Manager respectively.
Which of the following commands can be used to lock the user harold so that he cannot logon? Select all that apply.

passwd -l harold
passwd -r harold
usermod -L harold
lock harold
lock -l harold





The correct answer is passwd -l harold, and usermod -L harold. There is no command called lock.
What port is normally used by POP3 (PostOffice Protocol Version 3)?
The answer is 110.
Which of the following allow you to edit the cron jobs for the current user?

crontab -e
crontab -l
crontab -r
crontab -m




The answer is crontab -e. The -l option will display, but not change the entries, the -r option will remove the entries and -m is not a valid option.
What option needs to be used to allow the ping command to be used against a broadcast address? Enter the option only (do not include the command or any ip addresses).
The answer is -b.
Which file normally holds the default values used when creating a new user?

/etc/default/useradd.conf
/etc/default/useradd
/etc/useradd/default
/etc/useradd/default.conf
/etc/useradd.conf





the answer is /etc/default/useradd.
If you connect to tcp port 22 what service would you normally be using?

ftp
telnet
ssh
chargen
smtp





The answer is ssh. The port numbers of the other services are:
ftp = 21 (and 20 ftp-data)
telnet = 23
chargen = 19
smtp = 25



Which of the following time formats are valid for use with the at command? Select all that apply.

11:30
10am Jul 31
1am tomorrow
teatime
breakfast





The answers are: 11:30, 10am Jul 31, 1am tomorrow and teatime. All the options are valid except for breakfast.
What option to the netstat command will give the response as IP addresses without attempting to resolve to DNS names? Enter the option only (do not include the command or any ip addresses).
The answer is -n.
What command is commonly run on a daily basis to manage the log files by archiving or removing old entries? Enter the filename only.
The answer is logrotate.

Add Cards

You must Login or Register to add cards