Mr Vlad is correct, however in some older versions
of 'find' you also need to add the -print option
or you won't get any output. Nowadays it's the
default so you don't need to add it. Also, you
may not want to start in the root directory (/)
as the search will cover all reachable subdirectories
generating lots of error messages where you don't
have execute permission. A typical solution for
this problem is to redirect all the error messages
to /dev/null (the rathole) like this:
find / -name filename -print 2>/dev/null
Remember, that first slash / is the root directory.
Provide a starting place farther down the hierarchy
if you want the search to run faster. The 'find'
command recurses through all lower subdirectories
from the point where you start it.
Dick S.
You avoid the error messages by redirecting
them to /dev/null as I mentioned in my
previous post. Try this:
find / -name filename -print 2>/dev/null
Dick S.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.