Home Reverse colors Help
Single page Previous Contents Next

Introduction to GNU/Linux
47 / 102

Input/Output

Standard Input, Standard Output and Standard Error

In general, a command (a program):

These three are files, and are always open. As all open files, they are assigned to a file descriptor (an integer).

File descriptors for stdin, stdout and stderr.
File File descriptor
/dev/stdin or /dev/fd/0 0
/dev/stdout or /dev/fd/1 1
/dev/stderr or /dev/fd/2 2

Previous Contents Next
Contact