Main Page | See live article | Alphabetical index

/dev/null

/dev/null is a virtual device that erases all data written to it.

All of the devices on a computer running a Unix-like operating system are located under the tree /dev . The null device is usually /dev/null and can be used for disposing of unwanted outputs, for example. This is usually done by redirection. Everything copied into or sent to the Null device is simply lost and never shows up anywhere.

In 1995 the German magazine c't made up a report for an enhanced Null device with hardware support as an April Fool's joke. This was done by placing a LED inside a chip on the mainboard and explaining that all the data sent to the enhanced Null device was converted to flickering of the LED - if you removed the black cap that caught the red light, the performance of the enhanced Null device was lowered drastically. This report was several pages long, complete with benchmarks showing the great improvement of the hardware-supported Null device with respect to the usual software interface.