bash echo stderr code example Example 1: bash echo to stderr >&2 echo "error" Example 2: echo str terminal meaning It writes arguments to the standard output.