Operating Systems

A technician needs to locate every file named backup.conf somewhere under the /etc directory tree. Which command does this?

Show the answer

Correct answerB. find /etc -name backup.conf

AWhy not this: ls only lists directory contents and does not search subdirectories for a name this way.

BWhy this is right: find walks the directory tree from /etc and matches file names with -name.

CWhy not this: grep searches the text inside files, not file names, so it would not locate this file by name.

DWhy not this: pwd prints the current working directory and takes no search arguments.

find searches a directory tree for files by attributes such as name, so find /etc -name backup.conf walks /etc and returns matching paths. grep searches inside file contents for text, so it would look for the string rather than a file with that name.