Which of the following commands changes the ownership of file.txt to the user dan and the group staff?



A.

chown dan/staff file.txt

B.

chown dan:staff file.txt

C.

chown -u dan -g staff file.txt

D.

chown dan -g staff file.txt

題解

「chown」指令可以改變檔案的擁有者和群組。選項B是正確用法,將「file.txt」的檔案擁有者改成「dan」,群組改成「staff」。