From LQWiki
/dev/null is the Unix null device used as a data sink -- it loses all data that is written to it. It may be helpful to think of it as a black hole or garbage can that never gets full.
While at first glance this device may not appear to be useful, it in fact has many uses, most commonly in scripting.
Because a program will normally output error messages to its standard error stream, which is not passed on to another program in a pipeline, you may want to suppress program warnings sent to that stream that does not affect the running of your script. More concretely, you may merely run a program to see its error status, and so the program's output is discarded as such. The program's output can be then redirected to write to /dev/null and the output will not be shown on screen.
/dev/null is also used if a program wants input, and you do not want to supply any input. In this case, the program receives an immediate end of file indicator.
Given its nature as a trash can, /dev/null is often used non-literally. For example, many man pages end with "Send complaints to /dev/null." Also, a controversial posting, for example, might end “Kudos to rasputin@kremlin.org, flames to /dev/null”.
A notional ‘black hole’ in any information space being discussed, used, or referred to.
See the Jargon File entries:
This article is based, in whole or in part, on entry or entries in the Jargon File.

This page is available under a