Commands And Permissions In Linux: Quiz!

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Roobina_naaz
R
Roobina_naaz
Community Contributor
Quizzes Created: 2 | Total Attempts: 5,076
| Attempts: 2,038 | Questions: 21
Please wait...
Question 1 / 21
0 %
0/100
Score 0/100
1. What is the symbolic representation of this numeric permission: 644?

Explanation

The symbolic representation of the numeric permission 644 is "rw-r--r--". In this representation, the first character "rw-" indicates that the owner of the file has read and write permissions, the next three characters "r--" indicate that the group members have only read permissions, and the last three characters "r--" indicate that others (users not in the owner's group) also have only read permissions.

Submit
Please wait...
About This Quiz
Commands And Permissions In Linux: Quiz! - Quiz

This quiz focuses on understanding and managing file permissions in Linux. It tests your ability to interpret and modify permissions, explores system directories, and utilizes commands to manage... see morehidden files, enhancing system administration skills. see less

2. What command should we use to show the all hidden directory contents?

Explanation

To show all hidden directory contents, we should use the command "ls -a". The "-a" option in the "ls" command stands for "all" and it displays all files and directories, including the hidden ones. This allows us to see the contents of directories that are normally not visible.

Submit
3. To check the history we used _____________ command.

Explanation

The correct answer is "history" because the command "history" is used to check the command history in a terminal or command prompt. It displays a list of previously executed commands, along with their corresponding line numbers. This allows users to quickly access and rerun previous commands without having to retype them.

Submit
4. In which directory the booting file is save?

Explanation

The booting file is saved in the "boot" directory. This directory contains essential files for the system's boot process, including the bootloader and kernel.

Submit
5. Given a file with permission 755, what commands would change the permission to r-xr--r--?

Explanation

The correct answer is "chmod 544 filename". This command changes the permission of the file to r-xr--r--, where the owner has read, write, and execute permissions, and the group and others have only read permissions. The "chmod" command is used to change the permissions of a file, and the numbers 544 represent the octal representation of the desired permissions. The first digit (5) represents the owner's permissions, the second digit (4) represents the group's permissions, and the third digit (4) represents the permissions for others.

Submit
6. Bob Armstrong, who has a username of boba, calls to tell you he forgot his password. What command should you use to reset his command?

Explanation

To reset Bob Armstrong's password, the correct command to use is "passwd boba". The "passwd" command is used to change a user's password, and by specifying "boba" after the command, it indicates that the password being changed is for the user with the username "boba".

Submit
7. What is LINUX SHELL?

Explanation

The Linux shell is a user interface that allows users to interact with the operating system by executing commands. It provides a command-line interface where users can input commands and receive output from the system. The Linux shell is responsible for interpreting and executing these commands, allowing users to perform various tasks and manage the system efficiently.

Submit
8. What type of server is used to remotely assign IP addresses to machines during the installation process?

Explanation

C - You can use a DHCP server to assign IP addresses to individual machines during the installation process. Answers a, b, d, and e-list legitimate Linux servers, but these servers do not provide IP addresses. The SMB, or Samba, tool is used for file and print sharing across multi-OS networks. An NFS server is for file sharing across Linux net-works. FTP is a file storage server that allows people to browse and retrieve information by logging in to it, and HTTP is for the Web.

Submit
9. The user specific document save in the /usr directory?

Explanation



Typically, user-specific documents are not saved in the /usr directory. The /usr directory in Unix-like operating systems contains user-independent files, such as system binaries, libraries, and documentation. User-specific documents are often saved in directories within the user's home directory or other locations specific to the user.
Submit
10. All the logs and variables install in which directory?

Explanation

not-available-via-ai

Submit
11. Which file defines all users on your system?

Explanation

A - The /etc/passwd file contains all the information on users who may log into your system. If a user account is not contained in this file, then the user cannot log in.

Submit
12. Which two commands can you use to delete directories?

Explanation

B, C - You can use rmdir or rm -rf to delete a directory. Answer a is incorrect because the rm command without any specific flags will not delete a directory, it will only delete files. Answers d and e point to a non-existent command.

Submit
13. Which password package should you install to ensure that the central password file couldn't be stolen easily?

Explanation

D - The shadow password package moves the central password file to a more secure location. Answers a, b, and e all point to valid packages, but none of these places the password file in a more secure location. Answer d points to an invalid package.

Submit
14. You attempt to use shadow passwords but are unsuccessful. What characteristic of the /etc/passwd file may cause this?

Explanation

D - The password field must not be blank before converting to shadow passwords.

Submit
15. When using useradd to create a new user account, which of the following tasks is not done automatically.

Explanation

C - The useradd command will use the system default for the user's home directory. The home directory is not created, however, unless you use the -m option.

Submit
16. In linux, how many types of way we have?

Explanation

The correct answer is 2 because in Linux, there are two main types of ways: command line interface (CLI) and graphical user interface (GUI). CLI allows users to interact with the system through text commands, while GUI provides a visual interface with icons and menus. These two ways offer different levels of control and convenience, catering to the preferences and needs of different users.

Submit
17. There are seven fields in the /etc/passwd file. Which of the following lists all the fields in the correct order?

Explanation

B - The seven fields required for each line in the /etc/passwd file are username, UID, GID, comment, home directory, command. Each of these fields must be separated by a colon even if they are empty.

Submit
18. To list the directory contents with permissions the command is...........

Explanation

The command "ls -Z" is used to list the directory contents with permissions. The "-Z" option displays the SELinux security context of each file or directory. This can be useful for checking the permissions and access control settings of the listed files. The other options listed (-z, -/Z, -/z) are not valid options for the "ls" command.

Submit
19. What command is used to remove the password assigned to a group?

Explanation

C - The gpasswd command is used to change the password assigned to a group. Use the -r option to remove the password from the group.

Submit
20. You are covering for another system administrator and one of the users asks you to restore a file for him. You locate the correct tarfile by checking the backup log but do not know how the directory structure was stored. What command can you use to determine this?

Explanation

D - The only way to enlarge a partition is to delete it and recreate it. You will then have to restore the necessary files from backup.

Submit
21. To shut down the machine which command should we use?

Explanation

The correct answer is "shutdown -h now" and "poweroff". Both of these commands are used to shut down a machine. "shutdown -h now" is a command that initiates an immediate shutdown of the system and halts all processes. "poweroff" is another command that can be used to power off the machine. Both commands achieve the same result of shutting down the machine.

Submit
View My Results

Quiz Review Timeline (Updated): Mar 1, 2024 +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Mar 01, 2024
    Quiz Edited by
    ProProfs Editorial Team
  • Aug 24, 2010
    Quiz Created by
    Roobina_naaz
Cancel
  • All
    All (21)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
What is the symbolic representation of this numeric permission: 644?
What command should we use to show the all hidden directory contents?
To check the history we used _____________ command.
In which directory the booting file is save?
Given a file with permission 755, what commands would change the...
Bob Armstrong, who has a username of boba, calls to tell you he forgot...
What is LINUX SHELL?
What type of server is used to remotely assign IP ...
The user specific document save in the /usr directory?
All the logs and variables install in which directory?
Which file defines all users on your system?
Which two commands can you use to delete directories?
Which password package should you install to ensure that ...
You attempt to use shadow passwords but are ...
When using useradd to create a new user account, which of the...
In linux, how many types of way we have?
There are seven fields in the /etc/passwd file. Which ...
To list the directory contents with permissions the command...
What command is used to remove the password assigned to a group?
You are covering for another system administrator and ...
To shut down the machine which command should we use?
Alert!

Advertisement