Final Exam Flashcards
(43 cards)
A pipe allows you to…
- …type multiple commands at one prompt.
- …send the output of a command to a file.
- …send the same input to multiple commands.
- …send the output of one command to another.
…send the output of one command to another.
Channel 2 is:
- STDOUT
- STDERR
- STDIN
- STDALL
STDERR
The grep command…
- …will display the line numbers in a file that contain a specified Regular Expression.
- …will display all the lines in a file containing the specified Regular Expression.
- …will display all the lines that begin with the specified Regular Expression.
- …is not case sensitive.
…will display all the lines in a file containing the specified Regular Expression.
Which of the following commands can be used to scroll through a text file?(choose two)
- more
- cat
- some
- less
- more
- less
Which command can be used to print line numbers?
- num
- nl
- ln
- sort
nl
Which are appropriate editors for writing shell scripts?(choose two)
- nano
- vi
- LibreOffice Writer
- Firefox
- /bin/bash
- nano
- vi
Which of the following are correct about for and while loops?(choose two)
- for loops require a variable over which to iterate
- for loops have a test each cycle to determine if it should run again
- while loops have a test each cycle to determine if it should run again
- for loops operate over a fixed list of items
- while loops operate over a fixed list of items
- while loops have a test each cycle to determine if it should run again
- for loops operate over a fixed list of items
What is the correct way to assign the word “Hello” to a variable?
- $A=”Hello”
- echo “Hello” > A
- A=”Hello”
- A = “Hello”
- echo $A “Hello”
A=”Hello”
What is the correct way to save the current directory to a variable?
- pwd $A
- pwd | $A
- A=`pwd`
- A=pwd
- A=cwd
A=`pwd`
What is the meaning of $(( $i + 1)) ?
- This runs the command stored in variable i
- 1 will be added to the i variable
- If i is 0, the loop will stop
- This will return the value of the first argument to the script
- This will return the value of the next argument to the script
1 will be added to the i variable
Which of the following are valid CPU types for Intel-based platforms?(choose two)
- 24-bit
- 32-bit
- 48-bit
- 64-bit
- 32-bit
- 64-bit
Choose all of the following statements that are true in regard to virtual RAM: (choose three)
- Virtual RAM is stored in the CPU
- Virtual RAM is also called swap space
- Virtual RAM is stored on a hard drive
- Virtual RAM is used when available physical RAM is low.
- Virtual RAM is also called swap space
- Virtual RAM is stored on a hard drive
- Virtual RAM is used when available physical RAM is low.
A division of a hard drive may be referred to as a _______ .
- label
- portion
- partition
- block
- partition
The fdisk command is a tool used for working with the MBR partitioned disks. True or False?
True
Which of the following commands will display CPU information?(choose two)
- arch
- showcpu
- lspic
- cpuinfo
- lscpu
- arch
- lscpu
The Process ID (PID) of the init process is:
- varies
- 1
- 100
- 0
1
What directory typically contains log files?
- /usr/log
- /proc/loc
- /var/log
- /log
/var/log
The /var directory has files that change over time. True or False?
True
Which of the following commands will allow you to view all processes on the system?(choose two)
- ps -A
- ps aux
- ps -eLf
- ps
- ps -ef
ps aux
Which directory is the root of the filesystem?
- /
- /root
- /sys
- /home
- /var
/
A service is…
- …a file that contains configuration information.
- …a feature provided by one computer to another.
- …another name for a computer’s hostname.
- …like an IP address.
…a feature provided by one computer to another.
Only servers have hostnames. True or False?
False
Which of the following are valid IPv4 addresses?(choose two)
- 192.301.25.25
- 192.105.10.10.2
- 192.105.10.10
- 10.33.55.77
- 192.105.10.10
- 10.33.55.77
Which of the following commands will allow you to log into a remote machine?
- netstat
- dig
- route
- ssh
ssh