I tried this on csh on a machine with:
SunOS hostname 5.6 Generic_105181-11 sun4u sparc SUNW,Ultra-1
And I got:
hostname% find /dir -name "foo*" 2>/dev/null
find: bad option 2
find: path-list predicate-list
Jacob Fugal
jpfugal@xxxxxxx
Brian McPherson wrote:
Jacob Fugal wrote:
Hello all,
Does anyone know a good way to avoid the "find: cannot read dir ' .
. . . ' Permission denied" lines when executing the find command. In
my experience it buries the useful information. I tried grep, but it
appears that the | grep only gets the output and find pours this not
very useful message to stderr. My only way around it is to sudo
find, but I'm not sudo on every machine. Any ideas? It's really
annoying.
Jacob Fugal
jpfugal@xxxxxxx
find foo 2> /dev/null
Sends stderr to /dev/null.
-Brian McPherson