In bash, inserting 1>&2 after a command redirects

In bash, inserting 1>&2 after a command redirects

In bash, inserting 1>&2 after a command redirects

A.
standard output to standard error.

B.
standard error to standard output.

C.
standard input to standard error.

D.
standard output to standard input.

E.
standard error to standard input.

Explanation:
Standard Input use < symbol and 0 is the integer value Standard Output use > symbol and 1 is the integer value Standard Erroruse 2> symbol and 2 is the integer value

Example:
find / – name passwd >allresult 1>&amp;2 : Redirects all standard output as well as standard error to allresult file. Where &amp; is the logical operator.



Leave a Reply 0

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