1 cat 0 1 2 2 cat 0 1 2 cat good nofile cat good nofile 2>&1 3 0 cat 0 1 2 sed 1 2 out−err.txt cat good nofile 2>&1 | sed −n −p > out−err.txt