010-160 : Linux Essentials Certificate Exam : Part 04
-
What is the purpose of the
PATH
environment variable?- It allows the execution of commands without the need to know the location of the executable.
- It increases security by preventing commands from running in certain locations.
- It specifies the location of a user’s home directory.
- It indicates the location of the default shell to be used when a user logs in.
- It contains the absolute path to the current directory.
-
Which of the following commands sets the variable USERNAME to the value bob?
-
set USERNAME bob
-
$USERNAME==bob
-
var USERNAME=bob
-
USERNAME<=bob
-
USERNAME=bob
-
-
FILL BLANK
What command displays manual pages? (Specify ONLY the command without any path or parameters.)
-
man
-
-
Which command copies the contents of the directory
/etc/,
including all sub-directories, to/root/
?-
copy /etc /root
-
cp -r /etc/* /root
-
cp -v /etc/* /root
-
rcp /etc/* /root
-
cp -R /etc/*.* /root
-
-
Which of the following commands puts the lines of the file
data.csv
into alphabetical order?-
a..z data.csv
-
sort data.csv
-
abc data.csv
-
wc -s data.csv
-
grep --sort data.csv
-
-
Which of the following examples shows the general structure of a for loop in a shell script?
-
for *.txt as file => echo $file
-
for *.txt ( echo $i )
-
for file in *.txt do echo $i done
-
for ls *.txt exec {} \;
-
foreach @{file} { echo $i }
-
-
Which operator in a regular expression matches the preceding character either zero or one time?
-
?
-
*
-
+
-
%
-
$
-
-
The file
script.sh
in the current directory contains the following content:#!/bin/bash echo $MYVAR
The following commands are used to execute this script:
MYVAR=value ./script.sh
The result is an empty line instead of the content of the variable
MYVAR.
How shouldMYVAR
be set in order to makescript.sh
display the content ofMYVAR
?-
!MYVAR=value
-
env MYVAR=value
-
MYVAR=value
-
$MYVAR=value
-
export MYVAR=value
-
-
What is the return value of a shell script after successful execution?
-
1
-
0
-
-1
-
-255
-
255
-
-
Which of the following commands creates the ZIP archive
poems.zip
containing all files in the current directory whose names end in.txt?
-
zip *.txt > poems.zip
-
zcat *.txt poems.zip
-
zip poems.zip *.txt
-
zip cfz poems.zip *.txt
-
cat *.txt | zip poems.zip
-
-
Which of the following statements are true regarding a typical shell script? (Choose two.)
- It has the executable permission bit set.
- It starts with the two character sequence
#!.
- It is located in
/usr/local/scripts/.
- It is located in
/etc/bash/scripts/.
- It is compiled into a binary file compatible with the current machine architecture.
-
Which of the following commands extracts the contents of the compressed archive
file1.tar.gz
?-
tar -czf file1.tar.gz
-
ztar file1.tar.gz
-
tar -xzf file1.tar.gz
-
tar --extract file1.tar.gz
-
detar file1.tar.gz
-
-
Which of the following commands finds all lines in the file
operating-systems.txt
which contain the termlinux,
regardless of the case?-
igrep linux operating-systems.txt
-
less -i linux operating-systems.txt
-
grep -i linux operating-systems.txt
-
cut linux operating-systems.txt
-
cut [Ll] [Ii] [Nn] [Uu] [Xx] operating-systems.txt
-
-
Which one of the following statements concerning Linux passwords is true?
- All passwords can be decrypted using the system administrator’s master password.
- Passwords may never start with a non-letter.
- Users cannot change their password once it has been set.
- Passwords are only stored in hashed form.
- Passwords may be at most six characters long.
-
Which of the following programs are web servers? (Choose two.)
- Apache HTTPD
- Postfix
- Curl
- Dovecot
- NGINX
-
Which of the following Linux Distributions is derived from Red Hat Enterprise Linux?
- Raspbian
- openSUSE
- Debian
- Ubuntu
- CentOS
-
Which of the following statements is true about Free Software?
- It is developed by volunteers only.
- It may be modified by anyone using it.
- It must always be available free of charge.
- It only runs on Linux.
- It is only distributed as a compiled binary.
-
How is a new Linux computing instance provisioned in an laaS cloud?
- The standard Linux installer has to be run through a remote console.
- After buying a Linux distribution, its vendor delivers it to a cloud instance.
- The installation has to be prepared in a local virtual machine which is then copied to the cloud.
- The cloud hosting organization provides a set of pre-prepared images of popular Linux distributions.
- A provider-specific configuration file describing the desired installation is uploaded to the cloud provider.
-
What are the differences between a private web browser window and a regular web browser window? (Choose three.)
- Private web browser windows do not allow printing or storing websites.
- Private web browser windows do not store cookies persistently.
- Private web browser windows do not support logins into websites.
- Private web browser windows do not keep records in the browser history.
- Private web browser windows do not send regular stored cookies.
-
What is the preferred source for the installation of new applications in a Linux based operating system?
- The vendor’s version management system
- A CD-ROM disk
- The distribution’s package repository
- The vendor’s website
- A retail store
Subscribe
0 Comments
Newest