Filtering stderr – or how to get rid of tar’s “socket ignored” message

This based on a very useful tip in Darren Patterson’s blog, something I was looking for for quite a while: When you want to filter out useless error from stderr messages, while keeping your stdout channel unaffected (e.g., to get rid of the annoying ‘socket ignored’ warnings issued by old version of GNU tar), bash is your friend:

        tar  <my_options> 2> >(grep -v 'socket ignored' >&2)
This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>