# combining unix stderr output with stdout

The problem is that when I run script x and redirect it to a file, all of the error messages come to the screen when I want them to also go to that file.

With bash shell, use:

program &gt; outputfile 2&gt;&amp;1

My colleague found this for me in the book [Unix Power Tools](http://oreilly.com/catalog/9780596003302/) which is available online at <span class="caps">UCLA</span> here. [http://proquest.safaribooksonline.com/0596003307](http://proquest.safaribooksonline.com/0596003307)