Unit2 - Subjective Questions

CSC202 • Practice Questions with Detailed Answers

1

Explain the significance of the Read, Write, and Execute permissions when applied to a file compared to when they are applied to a directory in Linux.

2

Describe how to change file permissions using the chmod command with the Octal (Numeric) method. Provide examples for setting specific permission sets.

3

What is the umask in Linux? Calculate the default file and directory permissions if the umask is set to 022.

4

Explain the three Special Permissions in Linux: SUID, SGID, and the Sticky Bit. Include their numeric values and symbolic representation.

5

Distinguish between Hard Links and Soft (Symbolic) Links in the Linux file system.

6

What are Access Control Lists (ACLs)? Explain how to view and set ACLs using getfacl and setfacl.

7

Explain the purpose of the following key directories in the Filesystem Hierarchy Standard (FHS): /etc, /var, /home, /bin, and /dev.

8

What is an Inode? List the information stored within an inode.

9

Explain the usage of the find command. Provide command examples to find files based on name, size, and modification time.

10

Compare the locate command with the find command regarding speed and accuracy.

11

Describe the three modes of operation in the vi/vim editor. How do you switch between them?

12

Explain the function of the chown and chgrp commands with syntax examples.

13

What are Wildcards (Globbing) in Linux? Explain the usage of *, ?, and [].

14

Explain the usage of the ls command. Describe the output and purpose of the options -l, -a, -h, and -R.

15

How does the grep command work? Provide examples for case-insensitive search and recursive search within directories.

16

Differentiate between cp, mv, and rm commands with respect to file management.

17

Explain the purpose of head and tail commands. How can tail be used to monitor log files in real-time?

18

What are file attributes in the context of the ls -l command? Break down the output string: drwxr-xr--.

19

Explain the Input/Output Redirection operators: >, >>, <, and 2>.

20

Describe the function of the wc, cut, and sort commands for managing text file content.