An administrator attempts to rename a file on a server but receives the following error.
The administrator then runs a few commands and obtains the following output:
Which of the following commands should the administrator run NEXT to allow the file to be renamed by any user?
A . chgrp reet files
B . chacl -R 644 files
C . chown users files
D . chmod -t files
Answer: D
Explanation:
The command that the administrator should run NEXT to allow the file to be renamed by any user is chmod -t files. This command uses the chmod tool, which is used to change file permissions and access modes. The -t option removes (or sets) the sticky bit on a directory, which restricts deletion or renaming of files within that directory to only their owners or root. In this case, since files is a directory with sticky bit set (indicated by t in drwxrwxrwt), removing it will allow any user to rename or delete files within that directory.
The other options are not correct commands for allowing any user to rename files within files directory. The chgrp reet files command will change the group ownership of files directory to reet, but it will not affect its permissions or access modes. The chacl -R 644 files command is invalid, as chacl is used to change file access control lists (ACLs), not permissions or access modes. The chown users files command will change the user ownership of files directory to users, but it will not affect its permissions or access modes.
Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 8: Managing Users and Groups; chmod(1) – Linux manual page
Latest XK0-005 Dumps Valid Version with 136 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund