Shell may often see:>/dev/null 2> & 1
Command results can be defined in the form of %>
/Dev/null indicates an empty device file.
> Indicates the redirection location, for example, Echo "123">/home/123.txt
1 indicates stdout standard output. The default value is 1. Therefore, ">/dev/null" is equivalent to "1>/dev/null"
2 indicates stderr standard error
& Indicates equivalent, 2> & 1, indicating that 2's output redirection is equivalent to 1
The statement in the title of this article:
1>/dev/null indicates that the standard output is redirected to an empty device file, that is, no information is output to the terminal. In other words, no information is displayed.
2> & 1 next, the standard error output redirection is equivalent to the standard output. Because the standard output has been redirected to the empty device file, the standard error output is also redirected to the empty device file.