010-160 · Question #75
The ownership of the file doku.odt should be changed. The new owner is named tux. Which command accomplishes this change?
The correct answer is C. chown tux doku.odt. This question tests knowledge of the correct Linux command used to change the ownership of a file.
Question
Options
- Achmod u=tux doku.odt
- Bnewuser tux doku.odt
- Cchown tux doku.odt
- Dtransfer tux: doku.odt
- Epasswd doku.odt:tux
How the community answered
(30 responses)- A3% (1)
- B7% (2)
- C90% (27)
Why each option
This question tests knowledge of the correct Linux command used to change the ownership of a file.
chmod modifies file permission bits (read, write, execute), not ownership - 'u=tux' is not valid chmod syntax.
'newuser' is not a standard Linux command; useradd/adduser create new user accounts and have no function for changing file ownership.
The chown (change owner) command is the standard Linux utility for changing file and directory ownership. The syntax 'chown tux doku.odt' assigns the user 'tux' as the new owner of the file 'doku.odt', directly fulfilling the requirement.
'transfer' is not a valid Linux command; no such utility exists for reassigning file ownership.
passwd is used to change user account passwords and has no capability to modify file ownership.
Concept tested: Linux chown command for changing file ownership
Source: https://man7.org/linux/man-pages/man1/chown.1.html
Topics
Community Discussion
No community discussion yet for this question.