250+ TOP MCQs on File Permissions and Answers

Linux / Unix questions and answers focuses on various Linux commands on File Management areas viz. file attributes, modes and permissions.

1. The file permission 764 means:
a) Every one can read, group can execute only and the owner can read and write
b) Every one can read and write, but owner alone can execute
c) Every one can read, group including owner can write, owner alone can execute
d) Every one can read and write and execute
Answer: c
Clarification: None.

2. The permission -rwxr–r– represented in octal expression will be
a) 777
b) 666
c) 744
d) 711
Answer: c
Clarification: None.

3. Effective user id can be set using following permission
a) 0777
b) 2666
c) 4744
d) 1711
Answer: c
Clarification: None.

4. Effective group id can be set using following permission
a) 0777
b) 2666
c) 4744
d) 1711
Answer: b
Clarification: None.

5. Sticky bit can be set using following permission
a) 0777
b) 2666
c) 4744
d) 1711
Answer: d
Clarification: None.

6. The permission -rwSr–r– represented in octal expression will be
a) 0777
b) 2666
c) 4744
d) 4644
Answer: d
Clarification: None.

7. The permission -rwxr-sr– represented in octal expression will be
a) 0777
b) 2766
c) 2744
d) 2754
Answer: d
Clarification: None.

8. If user tries to remove (rm) a readonly file (444 permission), what will happen?
a) The file is removed successfully (and silently)
b) The rm command prompts for a confirmation, the command is successful upon confirmation
c) The rm command prompts for a confirmation, however the operation fails because of insufficient permissions
d) The rm command fails because of insufficient permissions
Answer: b
Clarification: None.

9. A user does a chmod operation on a file. Which of the following is true?
a) The last accessed time of the file is updated
b) The last modification time of the file is updated
c) The last change time of the file is updated
d) None of the mentioned
Answer: c
Clarification: None.

10. If the umask value is 0002. what will be the permissions of new directory
a) 777
b) 775
c) 774
d) 664
Answer: b
Clarification: None.

11. What is the command to set the execute permissions to all the files and subdirectories within the directory /home/user1/direct
a) chmod –r +x /home/user1/direct
b) chmod –R +x /home/user1/direct
c) chmod –f –r +x /home/user1/direct
d) chmod –F +x /home/user1/direct
Answer: b
Clarification: None.

Here’s the list of Best Reference Books in

Leave a Reply

Your email address will not be published. Required fields are marked *