A Linux user is unable to write to a file named 'report.txt' located in a directory they own. Which of the following commands should the system administrator use to BEST resolve this issue?
The correct answer is 'chmod u+w report.txt', as the use of the 'chmod' command with the 'u+w' option grants the user (owner) of the file write permissions. This aligns most closely with the presented scenario, where a user is unable to write to their own file. The other options either set overly permissive rights, change group ownership which may not be needed, or use an invalid option.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What does the 'chmod' command do?
Open an interactive chat with Bash
What do the options 'u', 'g', and 'o' in the 'chmod' command represent?
Open an interactive chat with Bash
What are the risks of using 'chmod 777' on a file?