XK0-005 · Question #1801
XK0-005 Question #1801: Real Exam Question with Answer & Explanation
The correct answer is A: The user test needs to log out and log back in before editing the myfile file.. Group membership is only applied at login time. Having added “test” to the editors group, they must log out and log back in before the new group permissions take effect.
Question
A systems administrator changed the file permissions on the myfile file: $ sudo chmod g+w myfile $ ls -l myfile -rwxrwxr-x 1 admin editors C 2022-10-13 10:45 myfile Then the administrator added an existing user test to the editors group: $ sudo usermod -aG editors test However, the user test is still unable to edit the file. Which of the following solutions will fix this issue?
Options
- AThe user test needs to log out and log back in before editing the myfile file.
- BThe file is only writable by the root user, and the user test needs root permissions.
- CThe group for the user test needs to be reloaded by running sudo source /etc/group.
- DIn order to edit the file, additional permissions are required that the user test does not have.
Explanation
Group membership is only applied at login time. Having added “test” to the editors group, they must log out and log back in before the new group permissions take effect.
Topics
Community Discussion
No community discussion yet for this question.