On Thu, Jun 30, 2016 at 12:16:07PM +0100, Jonathan McDowell wrote:
On Thu, Jun 30, 2016 at 11:14:00AM +0100, Mark Rogers wrote:
Is there a quick way to search all text files for a string?
By "text file" I mean ASCII files, like log files, config files etc, but excluding binaries like executables, database files, etc?
What I want is something like: find / -type a -exec grep 192.168.100.1 {} ; .. or similar, except that I made up "-type a" for ascii.
(I'm trying to find all places that an IP address is mentioned so that I can change ones that need to be changed.)
Does "grep -r -I 192.168.100.1 /" not do what you want?
That was exactly what I was going to ask. :-)