Linux Questions & Answers – File Permissions – 1

This set of 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
View Answer

Answer: c
Explanation: None.

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

Answer: c
Explanation: None.

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

Answer: c
Explanation: None.
advertisement
advertisement

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

Answer: b
Explanation: None.

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

Answer: d
Explanation: None.
Sanfoundry Certification Contest of the Month is Live. 100+ Subjects. Participate Now!

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

Answer: d
Explanation: None.

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

Answer: d
Explanation: None.
advertisement

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
View Answer

Answer: b
Explanation: 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
View Answer

Answer: c
Explanation: None.
advertisement

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

Answer: b
Explanation: 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
View Answer

Answer: b
Explanation: None.

Sanfoundry Global Education & Learning Series – Linux Administration & Programming.

Here’s the list of Best Books in Linux Commands & Shell Programming.
Here’s the list of Best Books in Linux Kernel, Device-Drivers & System Programming.

To practice all questions on Linux Administration & Programming, here is complete set of 1000+ Multiple Choice Questions and Answers on Linux.

If you find a mistake in question / option / answer, kindly take a screenshot and email to [email protected]

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.