grep a text in all files code example Example 1: grep in all files grep -rni "string" * Example 2: ubuntu grep text in files grep -r "mydomain.com" /etc/apache2/