LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 05-23-2008, 08:53 AM   #1
Sathya
Member
 
Registered: Sep 2007
Posts: 33

Rep: Reputation: 15
General question regarding FIFO


Hi

This is a general question about using FIFO for interprocess communication.

Case:

Two processes A and B running in the same host want to communcate with each other. A sends a string of characters to B for processing. For this, a FIFO can be used as a communication mechanism. But the same thing can be achieved by using a FILE in append mode as a medium of communication. B (or even multiple processes) can open in append mode to write at the end of file and A can open in append mode itseld to read. If this is the case, which would be the ideal option to use in terms of simplicity in coding, in terms of performance etc? FIFO or a normal file?

Thanks,
Sathya
 
Old 05-23-2008, 10:16 AM   #2
JoeyAdams
Member
 
Registered: Jun 2006
Distribution: Kubuntu Hardy
Posts: 94

Rep: Reputation: 15
You may want to look into dbus, which is designed to streamline inter-process communication (though the dbus daemon needs to be running). Another option would be to create a shared memory mapping by mmapping a file, though that could get really complex. Either of these options would require that both programs use dbus/mmapping respectively.

Sorry I don't have clear details about the FIFO option, but hopefully the next poster will
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question on using select() function call with FIFO Sathya Programming 12 05-30-2008 09:33 AM
Question about reading/writing into a Named Pipes(FIFO) Sathya Programming 21 05-05-2008 08:39 AM
fifo help !! matlin Linux - Newbie 1 02-21-2008 01:51 PM
SPAM question - General Internet Security question LuggerHouse Linux - Security 1 09-07-2007 08:30 AM
FIFO question gauge73 Linux - Newbie 1 02-28-2003 11:39 PM


All times are GMT -5. The time now is 04:37 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration