grepping /etc, who put these pipes here?
Friday Jun 09, 2006
One minor annoyance I've encountered when switching between GNU/Linux and Solaris is that Solaris lays some pipes in the /etc directory. So if you happen to be logged in as root and you do something like this:
grep foobar /etc/*
Then your grep may hang for a very long time, seemingly trying to read from the /etc/initpipe pipe. The solution is to only grep files (not pipes) with something like this:
grep foobar `find /etc/* -type f -print`
This searches all of the subdirectories under /etc so it still isn't as quick as I'd like. I'm sure someone out there has a more elegant way of doing this. And I suspect there is a very good reason why rusty old pipes are laying around where folks can trip over them.











Posted by Dan Price on June 11, 2006 at 01:08 AM GMT+00:00 #
Posted by bnitz on June 12, 2006 at 09:12 AM GMT+00:00 #