Sponsored Content
Top Forums Programming forks, ipc, fifos, update issues... Post 85006 by Funktar on Friday 30th of September 2005 02:26:00 AM
Old 09-30-2005
the only array index is inside tasktable, which i've tested on a nonforking program multiple adds and removes, etc. and it all works fine. updating it with 2 processes apparenlty doesn't share.
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

forks....HELP!!! someone anyone?

Hey guys, I'm given this bit of code, but, I'm having some problems executing it with the functions I've defined so far. I'm suppose to define the funtions "parse" and "execute." Parse splits the command in buf into individual arguments. It strips whitespace, replacing those it finds with NULLS... (3 Replies)
Discussion started by: richardspence2
3 Replies

2. Programming

Praying for help: FIFOs, IPC

omg i need help so bad. I've been working on a school project for what seems like an eternity and i'm close to deadline. Using FIFO's (i ahve to) to communicate between parent and child proc's. Right now I'm stuck on a read/write. fifomsg is a struct with int length and char message fields. ... (5 Replies)
Discussion started by: Funktar
5 Replies

3. Linux

A little help understanding FIFOs?

This isn't strictly a Linux question, but... I've been working on a project to archive some streaming media for time shifting using 'mplayer' and have been using FIFOs to archive in Ogg Vorbis format: mkfifo program_name.wav (mplayer -ao pcm -aofile program_name.wav &)... (0 Replies)
Discussion started by: deckard
0 Replies

4. UNIX for Advanced & Expert Users

tar and fifos

How can I make tar read data from a fifo, instead of storing it as a fifo? (8 Replies)
Discussion started by: Corona688
8 Replies

5. UNIX for Advanced & Expert Users

Question on forks and pipes

I am trying to figure out why when i have the following code int main( { printf("0\n"); fork(); printf("1\n"); exit(0);} and type in the shell a.out | cat the output of this program is 0 1 0 1 instead of 0 1 1 does anyone know? (3 Replies)
Discussion started by: Phantom12345
3 Replies

6. Programming

read from file using forks

i'm tring to make 2 processes each read from the same file but only one of them read the file. FILE * fileptr1; fileptr1 = fopen("file1.txt","rt"); pid2=fork(); while(1) { fscanf(fileptr1,"%s",temp1); if(feof(fileptr1)==0) { printf("%i",getpid()); //id of current process ... (6 Replies)
Discussion started by: ddx08
6 Replies

7. UNIX for Advanced & Expert Users

UNIX domain sockets vs FIFOs

Is there a performance advantage of one of these over the other? Obviously, it makes no sense to use normal TCP sockets or UDP sockets w/ the overhead they carry. But what about UNIX domain sockets vs FIFOs? I'd think they'd be very similar, in terms of performance and in terms of how they're... (2 Replies)
Discussion started by: mgessner
2 Replies

8. Solaris

errors on Netra-440: "IPC Warning: ipc: tcp_protocol: bad magic number"

I was asked to look into a problem with a Sun Netra 440 in another department. On the server in question, the relevant 'uname -a' information is, "SunOS host1 5.9 Generic_118558-16 sun4u sparc SUNW,Netra-440". That information aside, while the other admin is logged into the ALOM, these errors are... (0 Replies)
Discussion started by: Borealis
0 Replies

9. Programming

kill() function problem in client-server ipc message using 2 FIFOs

I want to have a message send & receive through 2 uni-direction FIFO Flow of data FIFO1 stdin--->parent(client) writefd--->FIFO1-->child(server) readfd FIFO2 child(server) writefd2---->FIFO2--->parent(client) readfd2--->stdout I need to have boundary structed message... (3 Replies)
Discussion started by: ouou
3 Replies

10. Red Hat

Issues after update

Hi guys, thanks for your kind assistance. I have a rhel6.4 server. After I did an update, the server does not reboot. Also user logins take for ever. Please any help on this matter will be appreciated . Thank you (2 Replies)
Discussion started by: cjashu
2 Replies
RENDEZVOUS(2)							System Calls Manual						     RENDEZVOUS(2)

NAME
rendezvous - user level process synchronization SYNOPSIS
#include <u.h> #include <libc.h> ulong rendezvous(ulong tag, ulong value) DESCRIPTION
The rendezvous system call allows two processes to synchronize and exchange a value. In conjunction with the shared memory system calls (see segattach(2) and fork(2)), it enables parallel programs to control their scheduling. Two processes wishing to synchronize call rendezvous with a common tag, typically an address in memory they share. One process will arrive at the rendezvous first; it suspends execution until a second arrives. When a second process meets the rendezvous the value arguments are exchanged between the processes and returned as the result of the respective rendezvous system calls. Both processes are awakened when the rendezvous succeeds. The tag space is common to processes in the same file name space, so rendezvous only works between processes in the same file name space. If a rendezvous is interrupted the return value is ~0, so that value should not be used in normal communication. SOURCE
/sys/src/libc/9syscall SEE ALSO
segattach(2), fork(2) DIAGNOSTICS
Sets errstr. BUGS
The correlation of rendezvous tags and file name space is a historical accident. If two unrelated processes happen to be in the same name space and do a rendezvous, trouble will result. The solution is to call rfork(RFNAMEG) (see fork(2)) in programs that use rendezvous unless they need to share the name space with their parent. This is especially important in Alef programs. RENDEZVOUS(2)
All times are GMT -4. The time now is 01:20 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy