/dev/null과 Redirection
by 담배맛구마[http://linux.about.com/cs/linux101/g/slshdevslshnull.htm]
Definition: /dev/null
On UNIX, this is a virtual-file that can be written to. Data written to this file gets discarded.
It is similar to the file call NUL on Windows machines.
Key point: When rooting a machine, intruders will often redirect logging to /dev/null For example, the command ln -s /dev/null .bash_history will cause the system to stop logging bash commands.
Culture: In the vernacular, means much the same thing as black hole. Typical usage: if you don't like what I have to say, please direct your comments to /dev/null.
/dev/null
1>/dev/null과 동일하다.
1>/dev/null
STDOUT(Standard Output)을 /dev/null로 redirection한다.
2>/dev/null
STDERR(Standard Error)을 /dev/null로 redirection한다.
2>&1
STDERR을 STDOUT으로 redirection
블로그의 정보
정윤상이다.
담배맛구마