thumbnail

Common Linux Commands

Type in the correct command that would do said task in the command line interface on Linux
Quiz by
JRBerger
Rate:
Last updated: February 6, 2021
You have not attempted this quiz yet.
First submittedFebruary 6, 2021
Times taken371
Average score60.0%
Report this quizReport
5:00
Enter answer here
0
 / 20 guessed
The quiz is paused. You have remaining.
Scoring
You scored / = %
This beats or equals % of test takers also scored 100%
The average score is
Your high score is
Your fastest time is
Keep scrolling down for answers and more stats ...
Hint
Answer
Edits contents of a text file
vi
Changes Current Directory
cd
Print Working Directory
pwd
Starts a new Bourne-again shell command
bash
Displays information about the command
info
Copies files & Directories from one location to another
cp
Displays the manual page
man
Switch User Accounts
su
Displays a detailed list of directory contents
ls -l
Displays contents of directory & all subdirectories
ls -r
Hint
Answer
Shutsdown Computer Securely
shutdown
Deletes files & Directories from the file system
rm
Displays a brief summary of how to use a command
--help
Displays all Files
ls -a
Displays contents of a text file on screen, but pauses one screen at a time
less
Moves &/or renames files
mv
Displays contents of a text file on screen
cat
Displays IP Address & Subnet Mask
ifconfig
Displays the first few lines of a text file
head
Displays the last few lines of a text file
tail
Save Your Stats
Your Next Quiz
How many countries do you know? In this quiz, you've got 15:00 to name as many as you can. Go!
Name all 50 states in the USA. Easy, right?
Can you name the capitals cities of all 196 countries in the world?
Drag the pin onto the correct country. Careful, though! Three wrong moves and the game ends.
5 Comments
+2
Level 68
Feb 18, 2021
Thanks for that. I have a quiz on the most popular Linux distros if you want to check it out: https://www.jetpunk.com/user-quizzes/156455/name-the-top-50-linux-distros
+1
Level 24
Feb 19, 2021
I only got three right x.x, but thank you for sharing. I got a lot to learn :D
+1
Level 70
Oct 18, 2021
Unfortunately I think a lot of these would be considered the wrong answer.

(e.g. ls -r is typically not as useful as find and would be more commonly used - also edit a file should be many more options than just vi [ed/vim/emacs/cat ;)])

Still, love to see Linux quizzes, good job!

+1
Level 55
Feb 17, 2022
1. Vi isn't the only text editor

2. the command to 'display all files' is tree /. I think you meant display all files in current directory.

+1
Level 24
May 22, 2022
Thank you. I'm still learning a lot about Linux, and am not entirely sure the best way to make quizzes on it.