2
votes
2answers
99 views

Pipe command to tail: when is the first command aborted?

In this example: $ for i in {1..3}; do sleep 1; echo $i; done | head -n 2 why is the first command (for loop) killed only just before the 3 is displayed ? I expected it to be killed right after ...
5
votes
2answers
1k views

Why does Subversion give a broken pipe error when piped into head?

If I do a svn log | head after the tenth line of output I get an error message: svn: Write error: Broken pipe What's going on here? I haven't seen any other command do this when used with head. ...
1
vote
0answers
225 views

Why does this pipeline get SIGTTIN?

When I run the command for i in *.log; do cat "$i" | sort; done | more, the pipeline gets a SIGTTIN signal and is stopped. bash$ for i in *.log; do cat "$i" | sort; done | more ### (one screenful of ...