IO Redirection In Linux
Open a File for reading and associate with Standard Input (STDIN)
< file
Use the current input stream as Standard Input for the program until “token” is seen. This is used in scripting:
<< token
Open a file for writing and truncate it and associate it with Standard Output:
file
Open a file for writing and seek to the end and associate it with Standard Output.It is used to append text to a file using a redirection operator.
file
Redirect FD n to the same place as FD m :
n>&m
Eg :
2>&1
This means send STDERR to the same place that STDOUT is going to.