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 taken237
Average score60.0%
Rating2.80
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
Switch User Accounts
su
Displays a detailed list of directory contents
ls -l
Print Working Directory
pwd
Displays contents of a text file on screen, but pauses one screen at a time
less
Copies files & Directories from one location to another
cp
Displays a brief summary of how to use a command
--help
Changes Current Directory
cd
Displays the last few lines of a text file
tail
Displays the manual page
man
Displays IP Address & Subnet Mask
ifconfig
Hint
Answer
Moves &/or renames files
mv
Displays all Files
ls -a
Displays contents of a text file on screen
cat
Displays information about the command
info
Displays contents of directory & all subdirectories
ls -r
Deletes files & Directories from the file system
rm
Displays the first few lines of a text file
head
Shutsdown Computer Securely
shutdown
Starts a new Bourne-again shell command
bash
Edits contents of a text file
vi
5 Comments
+2
Level 67
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 23
Feb 19, 2021
I only got three right x.x, but thank you for sharing. I got a lot to learn :D
+1
Level 67
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 53
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 23
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.