find command

I need help with the find command. I want to find all files that contain 'SCHD'.
Can anyone help me? :confused:

try this comand

find / -name "SCHD*" -type f -print

SCHD will not be in the name of the file. It will be in the contents. Is there any way to do this?

find / -type f | xargs grep -l SCHD

If you run into the problem of "Too many arguments", try this

find / -name '*.*' - exec grep 'SCHD' {} \; -print

Or, if that's too slow or you run into "No such file or directory" errors, try this:

find / -type f | while read file; do
  grep -l SCHD "$file"
done

Thanks for all your help! I got the information that needed. :slight_smile: