nerdexam
CompTIACompTIA

XK0-005 · Question #889

XK0-005 Question #889: Real Exam Question with Answer & Explanation

The correct answer is B: chown -R Ansible:Ansible /opt/Ansible. The -R flag applies the ownership change recursively, setting both the user and group of /opt/Ansible and all files/subdirectories within it to Ansible.

System Management

Question

A Linux administrator tries to install Ansible in a Linux environment. One of the steps is to change the owner and the group of the directory /opt/Ansible and its contents. Which of the following commands will accomplish this task?

Options

  • Agroupmod -g Ansible -n /opt/Ansible
  • Bchown -R Ansible:Ansible /opt/Ansible
  • Cusermod -aG Ansible /opt/Ansible
  • Dchmod -c /opt/Ansible

Explanation

The -R flag applies the ownership change recursively, setting both the user and group of /opt/Ansible and all files/subdirectories within it to Ansible.

Topics

#chown command#File ownership#Linux permissions#System administration

Community Discussion

No community discussion yet for this question.

Full XK0-005 PracticeBrowse All XK0-005 Questions