How to pipe standard error output

To flow the standard error output to the pipe, write as follows (in the case of sh and bash).

Pour standard error into a pipe

CommandA 2>&1 1>/dev/null | CommandB

Pour both standard output and standard error into a pipe

CommandA 2>&1 | CommandB

Associated Information