Site icon Ananova Business Web Hosting

Standard I/O & Error Redirection

Standard I/O & Error RedirectionThe numbers 0, 1, and 2 refer to the standard input, standard output, and standard error, respectively.

I/O Redirection

cat file1 file2 file3> new-file

Error Redirection

When a command fails to execute, the system issues an error message which gets displayed on a screen by default. To keep the record of the error messages, they are redirected to a file using special redirection operators.

Pipes

The Pipe | operator placed between two commands forms a connection between them. They make the CLI incredibly powerful, efficient and versatile. It creates a unidirectional data channel used for interprocess communication.

Named Pipe 

mkfifo <pipe-name>

mknod p <pipe-name>

Its special file, which follows FIFO (First-in, First-out character) mechanism used even over multiple shell sessions. The size of the named pipe is zero and has a designation of “p.” They resided in memory rather than being written to disk.

$ mkfifo hosting

$ ls -l hosting

64-bit computer architecture and availability of large memory computer systems enables the distribution of application among multiple processes, which communicate with each other using IPC (Interprocess communication). In a networking environment, these processes run on different systems.

Exit mobile version