Redirect error to null linux
In short: yes - redirect /dev/stderr to /dev/null. But, if you can't figure it out on your own, you shouldn't try, as you are more likely to break something fatally than succeed. – Benubird May 13 '13 at If you don't specify a number then the standard output stream is assumed but you can also redirect errors > file redirects stdout to file 1> file redirects stdout to file 2> file redirects stderr to file &> file redirects stdout and stderr to file /dev/null is the null device it takes any input you want and throws it away. It can be used to suppress any output. Lastly, 1>/dev/null redirects fd1 to /dev/null 0: /dev/tty, 1: /dev/null, 2: pipe End result, script's stdout is silenced, and its stderr is sent through the pipe, which ends up in other-script's stdin.
One thought on “Redirect error to null linux”