Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

whenever i execute find command for searching for some file


find . -name "abc"

specially from the root,it displays lots of "cannot open or cannot search "

how can suppress those messages?is there any flag for that?

share|improve this question

migrated from Apr 1 '11 at 18:42

This question came from our site for professional and enthusiast programmers.

You can direct the standard error stream to /dev/null, viz:

find . -name "abc" 2>/dev/null
share|improve this answer

you can suppress by piping stderr(2) to /dev/null or to a log file for later viewing

find . -name "abc" 2>/dev/null
find . -name "abc" 2>/errorlog.txt
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.