GNU bug report logs - #13075
fifo unlimited buffer size?

Previous Next

Package: coreutils;

Reported by: Peng Yu <pengyu.ut <at> gmail.com>

Date: Tue, 4 Dec 2012 03:22:01 UTC

Severity: normal

Tags: notabug

Done: Assaf Gordon <assafgordon <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Peng Yu <pengyu.ut <at> gmail.com>
To: 13075 <at> debbugs.gnu.org
Subject: bug#13075: fifo unlimited buffer size?
Date: Mon, 3 Dec 2012 21:19:02 -0600
Hi,

I have the following script. When the number to the right of 'seq' is
large (as 100000 in the example), the script will hang. But when the
number is small (say 1000), the script can be finished correctly. I
suspect that the problem is that there is a limit on the buffer size
for fifo. Is it so? Is there a way to make the following script work
no matter how large the number is? Thanks!

~/linux/test/gnu/gnu/coreutils/mkfifo/tee$ cat main2.sh
#!/usr/bin/env bash

rm -rf a b c
mkfifo a b c
seq 100000 | tee a > b &
sort -k 1,1n a > c &
join -j 1 <(awk 'BEGIN{OFS="\t"; FS="\t"} {print $1, $1+10}' < c)
<(awk 'BEGIN{OFS="\t"; FS="\t"}{print $1, $1+20}' < b)

-- 
Regards,
Peng




This bug report was last modified 6 years and 274 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.