Unix File System Commands and Permissions

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 Catherine Halcomb
Catherine Halcomb
Community Contributor
Quizzes Created: 2716 | Total Attempts: 6,914,665
| Questions: 30 | Updated: Jun 28, 2026
Please wait...
Question 1 / 31
🏆 Rank #--
0 %
0/100
Score 0/100

1. Which Unix file type handles character-by-character input/output?

Explanation

Character special files are designed to handle data as a stream of characters, allowing for character-by-character input and output. They facilitate direct communication with hardware devices, such as keyboards and serial ports, where data is processed one character at a time. This contrasts with block special files, which handle data in larger blocks. Therefore, character special files are essential for applications requiring immediate and sequential data processing.

Submit
Please wait...
About This Quiz
Unix File System Commands and Permissions - Quiz

This assessment focuses on Unix file system commands and permissions. It evaluates your understanding of essential commands like `mkdir`, `chmod`, and file types, helping you grasp critical concepts in file management. Mastering these commands is vital for effective navigation and manipulation within the Unix environment.

2.

What first name or nickname would you like us to use?

You may optionally provide this to label your report, leaderboard, or certificate.

2. Match each Unix command with its correct description.

Submit

3. The numeric permission `____` in Unix represents read and write (rw-) access.

Submit

4. A `____` link in Unix uses a different inode number and can work across file systems.

Submit

5. The `____` operator in Unix appends output to the end of a file without overwriting existing content.

Submit

6. The `____` command in Unix is used to display the list of files and directories in the current location.

Submit

7. What is the primary use of the `touch` command in Unix?

Submit

8. What does the `tee` command do in Unix?

Submit

9. What does the `>>` operator do in Unix?

Submit

10. Which of the following is TRUE about soft links compared to hard links?

Submit

11. Which of the following is TRUE about hard links compared to soft links?

Submit

12. What does `chmod 755 file.txt` set as the permission for the group?

Explanation

The command `chmod 755 file.txt` sets the file permissions in a specific format: the first digit (7) represents the owner's permissions (read, write, execute), the second digit (5) represents the group's permissions, and the third digit (5) represents others' permissions. The value 5 corresponds to read (4) and execute (1) permissions, but not write (2). Therefore, for the group, the permissions set are read and execute, which is represented as `r-x`.

Submit

13. What numeric value represents full read, write, and execute (rwx) permission in Unix?

Explanation

In Unix, file permissions are represented using a three-digit octal system, where each digit corresponds to a different set of permissions: read (4), write (2), and execute (1). Full permissions for a user, group, and others are achieved by summing these values. For example, read (4) + write (2) + execute (1) equals 7. Therefore, a numeric value of 7 indicates that all three permissions are granted, allowing complete access to the file or directory.

Submit

14. What does FIFO stand for in Unix?

Explanation

FIFO stands for "First In First Out," which is a method of processing data where the first element added to a queue is the first one to be removed. In Unix, FIFO refers to a type of named pipe that allows for inter-process communication. Data written to the FIFO is read in the same order it was written, ensuring a consistent and orderly flow of information between processes. This mechanism is essential for coordinating tasks and managing data streams in a multitasking environment.

Submit

15. Which Unix file type stores data in fixed-size blocks?

Explanation

Block special files are used in Unix to represent devices that read and write data in fixed-size blocks, such as hard drives. These files facilitate efficient data transfer by allowing the system to manage data in chunks, which is essential for performance when dealing with storage devices. In contrast, regular files store data sequentially, while character special files handle data as a stream of characters. Symbolic links are simply pointers to other files and do not store data themselves. Thus, block special files are specifically designed for block-oriented data storage.

Submit

16. What is a directory in Unix?

Explanation

In Unix, a directory is a special type of file that serves as a container for organizing other files and directories. It maintains a list of names and metadata about these contained files, allowing users to navigate the filesystem hierarchy efficiently. This structure is essential for managing files, as it enables easy access, categorization, and organization of data within the operating system. Each directory can also contain subdirectories, creating a tree-like structure that helps users locate files systematically.

Submit

17. Which command removes an empty directory in Unix?

Explanation

The command `rmdir` is specifically designed to remove empty directories in Unix. Unlike `rm`, which is used for removing files and can delete non-empty directories with the `-r` option, `rmdir` strictly enforces that the directory must be empty before it can be removed. This makes `rmdir` the appropriate choice for safely deleting directories without inadvertently affecting their contents.

Submit

18. What does the `mv` command do in Unix?

Explanation

The `mv` command in Unix is primarily used to move files from one location to another or to rename them. When you specify a source file and a destination, `mv` transfers the file to the new location. If the destination is a different name in the same directory, it effectively renames the file. This command does not create new files or remove them; instead, it changes the file's location or name while maintaining its original content.

Submit

19. Which command is used to copy files from one location to another in Unix?

Explanation

In Unix, the `cp` command is specifically designed for copying files and directories from one location to another. It allows users to duplicate files while preserving the original file in its initial location. The `mv` command is used for moving files, which removes the original after relocating it, while `ln` creates links to files, and `touch` is used to create empty files or update timestamps. Therefore, `cp` is the appropriate choice for the task of copying files.

Submit

20. What does the `ls` command do in Unix?

Explanation

The `ls` command in Unix is used to list files and directories in the current working directory or a specified path. It provides users with a quick overview of the contents of a directory, showing file names and sometimes additional details like file sizes and modification dates, depending on the options used. This functionality is essential for navigation and file management within the Unix file system.

Submit

21. Which command is used to change the current working directory in Unix?

Explanation

In Unix, the command used to change the current working directory is "cd," which stands for "change directory." When executed, it allows users to navigate between different directories in the filesystem. This command is essential for file management and organization, enabling users to access files and folders located in various parts of the directory structure. Other commands listed, such as "ls," "pwd," and "mkdir," serve different purposes, such as listing files, displaying the current directory, and creating new directories, respectively.

Submit

22. What is a soft link (symbolic link) in Unix?

Explanation

A soft link, or symbolic link, in Unix serves as a shortcut to another file or directory. Unlike a hard link, which directly references the same inode, a soft link contains a path to the target file. This means that if the original file is moved or deleted, the soft link will break, resulting in a "file not found" error. Soft links are useful for creating references to files across different directories without duplicating the actual file data. They enhance flexibility in file management and organization within the Unix file system.

Submit

23. How is a hard link defined in Unix?

Explanation

In Unix, a hard link is an additional name for an existing file that points directly to the same inode, which contains the file's data and metadata. This means that both the original file and the hard link refer to the same physical data on the disk. Changes made to the file through any of its hard links reflect in all links since they share the same inode. Unlike shortcuts or symbolic links, hard links cannot reference directories or files on different filesystems, ensuring consistency and integrity within the same filesystem.

Submit

24. What is a pipe (`|`) in Unix?

Explanation

In Unix, a pipe (`|`) is a powerful tool that allows the output of one command to be directly fed as input to another command. This enables users to create complex command sequences, enhancing the efficiency of data processing. For example, by using pipes, you can filter, sort, or manipulate data from one command without needing to store intermediate results in files. This streamlining of processes is fundamental to Unix's design, promoting a modular approach to command-line operations.

Submit

25. What does the `>` operator do in Unix?

Explanation

In Unix, the `>` operator is used for output redirection, specifically directing the output of a command to a specified file. When this operator is used, it will overwrite any existing contents of the file, replacing it with the new output. This is useful for saving the results of commands directly into files, but users should be cautious as it will erase any previous data in the file being targeted.

Submit

26. What is the purpose of the `chmod` command in Unix?

Explanation

The `chmod` command in Unix is used to modify the access permissions of files and directories. It allows users to specify who can read, write, or execute a file, thereby controlling access and enhancing security. By adjusting these permissions, users can ensure that only authorized individuals can interact with specific files, which is crucial for protecting sensitive information and maintaining system integrity.

Submit

27. What type of data does a regular file store in Unix?

Explanation

In Unix, a regular file is designed to store user data, which can include a variety of content types such as text documents, images, executable programs, and video files. Unlike special files that may represent devices or system information, regular files serve as the primary means for users to save and retrieve their data. This versatility allows users to manage and interact with their information efficiently, making regular files essential for everyday computing tasks.

Submit

28. Which command is used to remove a file in Unix?

Explanation

In Unix, the `rm` command is specifically designed to remove files and directories. Unlike `rmdir`, which only removes empty directories, `rm` can delete files regardless of whether they are empty or not. It is a powerful command that can also remove multiple files at once if specified. Users must exercise caution when using `rm`, as deleted files cannot be easily recovered. Other options like `del` and `mv` serve different purposes, making `rm` the appropriate choice for file removal.

Submit

29. Which command is used to create a new directory in Unix?

Explanation

In Unix, the `mkdir` command is specifically designed to create new directories. When executed, it allows users to specify the name of the directory they want to create. In contrast, `cd` is used to change directories, `rmdir` removes empty directories, and `touch` creates empty files or updates timestamps on existing files. Therefore, `mkdir` is the appropriate command for the task of creating a new directory.

Submit

30. What does the `pwd` command do in Unix?

Explanation

The `pwd` command stands for "print working directory." It is used in Unix and Unix-like operating systems to display the full path of the current directory in which the user is working. This command helps users confirm their location within the file system, making it easier to navigate and manage files and directories effectively.

Submit
×
Saved
Thank you for your feedback!
View My Results
Cancel
  • All
    All (30)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
Which Unix file type handles character-by-character input/output?
Match each Unix command with its correct description.
The numeric permission `____` in Unix represents read and write (rw-)...
A `____` link in Unix uses a different inode number and can work...
The `____` operator in Unix appends output to the end of a file...
The `____` command in Unix is used to display the list of files and...
What is the primary use of the `touch` command in Unix?
What does the `tee` command do in Unix?
What does the `>>` operator do in Unix?
Which of the following is TRUE about soft links compared to hard...
Which of the following is TRUE about hard links compared to soft...
What does `chmod 755 file.txt` set as the permission for the group?
What numeric value represents full read, write, and execute (rwx)...
What does FIFO stand for in Unix?
Which Unix file type stores data in fixed-size blocks?
What is a directory in Unix?
Which command removes an empty directory in Unix?
What does the `mv` command do in Unix?
Which command is used to copy files from one location to another in...
What does the `ls` command do in Unix?
Which command is used to change the current working directory in Unix?
What is a soft link (symbolic link) in Unix?
How is a hard link defined in Unix?
What is a pipe (`|`) in Unix?
What does the `>` operator do in Unix?
What is the purpose of the `chmod` command in Unix?
What type of data does a regular file store in Unix?
Which command is used to remove a file in Unix?
Which command is used to create a new directory in Unix?
What does the `pwd` command do in Unix?
play-Mute sad happy unanswered_answer up-hover down-hover success oval cancel Check box square blue
Alert!