Search For Specific Text In File

How can I find a specific text string in a file or multiple files from an SSH session?

You can use the grep command to easily find text within files.

From an SSH session, run the following command:

grep -H -r "<Text-To-Find>" <search-location>

Where <Text-To-Find> would be replaced with the text you want to search for and <search-location> is where the files are located that you want to search within.

For example, if you wanted the find all files containing the string "base64_decode" in the home folder, you would use:

grep -H -r "base64_decode" /home