Pipe & fifo size limit


 
Thread Tools Search this Thread
Top Forums Programming Pipe & fifo size limit
# 1  
Old 09-13-2010
Pipe & fifo size limit

Hi guys.

1. how much is the size of pipe?(i mean the buffer size)
2. is this size different in various UNIX derivations?
3. what happens if we write to a full pipe? does it block until get some free space(the other side receive data) or returns an error?
3. FIFO s are physical files on the system. so their size limit must be limited to the file system. am i right?
# 2  
Old 09-13-2010
Quote:
Originally Posted by majid.merkava
Hi guys.

1. how much is the size of pipe?(i mean the buffer size)
2. is this size different in various UNIX derivations?
As you suspected, this varies. I've heard 64KB stated sometimes, but it's not especially important.
Quote:
3. what happens if we write to a full pipe? does it block until get some free space(the other side receive data) or returns an error?
Unless you've configured it as nonblocking, it blocks.
Quote:
3. FIFO s are physical files on the system. so their size limit must be limited to the file system. am i right?
No. Their contents aren't stored on the filesystem.
# 3  
Old 09-13-2010
Thank you very much.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

UNIX fifo concurrent read from a named pipe

I have created a fifo named pipe in solaris, which writes the content of a file, line by line, into pipe as below: $ mkfifo namepipe $ cat books.txt "how to write unix code" "how to write oracle code" $ cat books.txt >> namepipe & I have a readpipe.sh script which reads the named... (2 Replies)
Discussion started by: naveen mani
2 Replies

2. Shell Programming and Scripting

awk reading from named pipe (fifo)

I'm trying to read a fifo using awk and comming across some problems. I'm writing to the fifo from multiple processes invoked by GNU Parallel: mkfifo my_fifo awk '{ a = a + $2 } END { for (i in a) print i, a }' my_fifo | sort -nk1 > sorted_output grep -v '^@' massive_file | parallel... (3 Replies)
Discussion started by: nathanhaigh
3 Replies

3. UNIX for Advanced & Expert Users

FIFO size in Solaris

Hi, How do I know the max. size for FIFO(named pipe) on my system. I'm using solaris 10 OS. Is there any comparison chart between message queues and named pipes. Thanks in advance. (4 Replies)
Discussion started by: axes
4 Replies

4. UNIX for Advanced & Expert Users

Why not SIGPIPE for readers of pipe/FIFO?

Hi This is a exercise question from Unix network programming vol2. Why the SIGPIPE signal is generated only for writers when readers disappear. why not it is generated for readers when writer disappears. I guess, if the writer didn't get any response like the reader gets EOF, it will... (4 Replies)
Discussion started by: kumaran_5555
4 Replies

5. UNIX for Dummies Questions & Answers

Search for & edit rows & columns in data file and pipe

Dear unix gurus, I have a data file with header information about a subject and also 3 columns of n rows of data on various items he owns. The data file looks something like this: adam peter blah blah blah blah blah blah car 01 30 200 02 31 400 03 57 121 .. .. .. .. .. .. n y... (8 Replies)
Discussion started by: tintin72
8 Replies

6. Linux

Limit directory size

Hello I want to limit the size of a directory; so a user cant copy more staff inside it then 5 Giga for example.. eg. /nfs/temp/jhon size can not increase more that 5Gb I havnt found anything on the net. Is there a way to do it? (2 Replies)
Discussion started by: jredx
2 Replies

7. UNIX for Dummies Questions & Answers

fifo or named pipe working?

Can someone explain to me the working of fifo() system call using simple C programs so that I can implement them in the UNIX environement? (1 Reply)
Discussion started by: lvkchaitanya
1 Replies

8. Shell Programming and Scripting

Reading from blocking fifo pipe in shell script

Hi!! I have a problem reading from a fifo pipe in shell script. The idea is simple, I have a C program with two pipe files: An input pipe I use to send commands in shell script to the C program (echo "command" > input.pipe) An output pipe that I read the result of the command also in... (4 Replies)
Discussion started by: victorin
4 Replies

9. UNIX for Advanced & Expert Users

PIPE and FIFO buffer size

Hello! How I can increase (or decrease) the predefined pipe buffer size? Thanks! (1 Reply)
Discussion started by: Jus
1 Replies

10. Programming

Pipe & fifo....

Could someone Help me with this code please? #include <stdio.h> #include <unistd.h> #include <sys/types.h> #include <sys/stat.h> #include <string.h> #include <fcntl.h> #define SIZE_B 256 /*buffer's size */ #define NUM_ARG 20 /* max number of args for any command */ int... (4 Replies)
Discussion started by: M3xican
4 Replies
Login or Register to Ask a Question