Cmd1 cmd2 Pipe stdout from cmd1 to stdin of cmd2.
I need help with redirecting errors to dev null.
Can anyone help, thanks, adv Reply, november 18th, 2009 #2.
The operator redirects the output usually to a file but it can be to a device.Ubuntu Logo, Ubuntu and Canonical Canonical Ltd.The chunk /dev/null is redirecting stdout to /dev/null.Tango Icons Tango Desktop Project.
For example, in some programs it is used to display information that would otherwise affect the output of the program window 7 product key 2014 (which is designed to be piped into another program).
A file descriptor can be a file name of the address of a stream.
As such, no output is produced and no mail is sent.
If any errors occur in the tar process (e.g.: permission denied, no such file or directory,.) the script will still crash.
Thanks The errors were sent to stdout by du and were not piped to grep.VBulletin, Jelsoft Enterprises Ltd.No, this will not prevent the script from crashing.I've been sending everything that du outputs to grep and grep was sending everything to stout (and errors too so doing 2 /dev/null wouldn't send anything to dev null because grep didn't have any errors, and all errors that have happened when executing du were.Re: Redirecting stderr to dev null?Originally Posted by xx77aBs hehe thank you!(if it's possible) Adv Reply November 18th, 2009 #6 Re: Redirecting stderr to dev null?Code: du -h -c grep total 2 /dev/null.