Question 180
A RHEL 10 administrator is reviewing ownership of /srv/team14/file14.txt. The requirement is to change both file owner and owning group, using account auditor and group qa where relevant. Which command meets it?
Explanation
Correct Answer
chown user:group updates both ownership fields for the named file. This matches the stated requirement to change both file owner and owning group, using account auditor and group qa where relevant. By contrast, the plausible alternative `chgrp qa /srv/team14/file14.txt` has the effect: chgrp updates the owning group without changing the file owner account. This changes or displays a different ownership field; that operation would not achieve the requested result.
Incorrect Answers
chgrp updates the owning group without changing the file owner account. This changes or displays a different ownership field. The stated task is to change both file owner and owning group, using account auditor and group qa where relevant. Instead, `chown auditor:qa /srv/team14/file14.txt` is the relevant alternative because chown user:group updates both ownership fields for the named file.
stat with %U and %G prints the owner and group names but makes no changes. This changes or displays a different ownership field. The stated task is to change both file owner and owning group, using account auditor and group qa where relevant. Instead, `chown auditor:qa /srv/team14/file14.txt` is the relevant alternative because chown user:group updates both ownership fields for the named file.
chown with a username alone changes owner, not the owning group. This changes or displays a different ownership field. The stated task is to change both file owner and owning group, using account auditor and group qa where relevant. Instead, `chown auditor:qa /srv/team14/file14.txt` is the relevant alternative because chown user:group updates both ownership fields for the named file.






Red Hat Certified System Administrator (RHCSA) (EX200) Practice Tests