exam questions

Exam XK0-005 All Questions

View all questions & answers for the XK0-005 exam

Exam XK0-005 topic 1 question 42 discussion

Actual exam question from CompTIA's XK0-005
Question #: 42
Topic #: 1
[All XK0-005 Questions]

A Linux administrator wants to set the SUID of a file named dev_team.text with 744 access rights. Which of the following commands will achieve this goal?

  • A. chmod 4744 dev_team.txt
  • B. chmod 744 --setuid dev_team.txt
  • C. chmod -c 744 dev_team.txt
  • D. chmod -v 4744 --suid dev_team.txt
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
linux_admin
Highly Voted 8 months, 4 weeks ago
A. chmod 4744 dev_team.txt The "chmod" command is used to change the access rights of a file in Linux. The "4744" options specify the access rights in binary form. The first number (4) represents the setuid (SUID) bit, which causes the file to run with the effective user ID of the owner of the file, rather than with the effective user ID of the user who is running it. The other three numbers (744) represent the permissions for the owner, group, and others, respectively. In this case, the owner has read, write, and execute permissions (7), the group has read and execute permissions (4), and others have only read permission (4). So, the command "chmod 4744 dev_team.txt" sets the SUID bit and the access rights to 744 for the file dev_team.txt. The SUID bit allows the file to be executed with the owner's permissions, which can be useful for setuid scripts or other special purpose files.
upvoted 8 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago