What is meant by the process of pipeline?

Just as the name depicts pipeline is the process in which when a pipe is set between two commands then the standard output from the first command is passed through the pipe specified to the second command and thus acts as an input to the second command. In other words the standard output of the first command is pipelined as standard input to the second command. This is done by using the symbol for pipeline as |. It is not necessary that the process of pipe is applied only for commands. That is one can even define the process of pipe between two programs where by the standard output of the first program is taken as standard input of the second program.


Let us see this concept of pipeline with a small example:


We know that who command in UNIX is used to display the list of users logged in. Suppose we like to get the output as sorted list of users logged in then we can achieve that by using the concept of pipeline as



who | sort



Thus the first command which is who gives output as list of users logged in which is pipelined to the second command sort as input and thus giving the list of sorted list of users logged in.

Questions by GeekAdmin   answers by GeekAdmin

 

This Question is not yet answered!

 
 

Related Answered Questions

 

Related Open Questions