The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > High Level Programming
.
google unix.com



High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Doubts on FIFO Akshay UNIX for Dummies Questions & Answers 0 06-06-2008 07:56 AM
FIFO Pipes tej.buch UNIX for Advanced & Expert Users 4 02-11-2006 02:01 AM
FIFO issue runawayNinja High Level Programming 1 04-29-2004 03:10 PM
FIFO over NFS saabir UNIX for Advanced & Expert Users 2 08-06-2003 08:03 AM
Pipe & fifo.... M3xican High Level Programming 4 07-20-2002 07:22 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 06-03-2006
atticus atticus is offline
Registered User
  
 

Join Date: Mar 2006
Posts: 18
how to use fifo

hi, I have a problem. I've done a lil program which gets from the server the given persons username a personal folder. I made it with a pipe calling popen with a command, but how can i make the same thing using fifo. I make the fifo with mkfifo() func. and than what. How do I tell the sertver using the fifo file that I need a persons usr name and personal folder.
any kind of help is appreciated.
  #2 (permalink)  
Old 06-03-2006
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,111
A fifo works pretty much like a pipe....
Code:
$ echo one two three | tr t T
one Two Three
$ mkfifo george
$ tr t T < george &
[1]     14967
$ echo one two three > george
$ one Two Three
$
[1] +  Done                    tr t T < george &
$
In both cases one process reads and the other process writes. This brings up the main difference, with modern pipes, it is possible to move data in both directions...but this is seldom done. A fifo is unidirectional only.
  #3 (permalink)  
Old 06-03-2006
cbkihong cbkihong is offline Forum Advisor  
Advisor
  
 

Join Date: Sep 2002
Location: Hong Kong, China
Posts: 1,624
For starters, you may find this page useful:

http://beej.us/guide/ipc/fifos.html
  #4 (permalink)  
Old 06-05-2006
grumpf grumpf is offline
Registered User
  
 

Join Date: May 2006
Posts: 101
Are you sure you need fifo's or is it only a trial ?
instead of fifo's you can easly use (unix-) sockets or do 'man socketpair' if you have to processes to connect.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 12:53 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0