Interprocess communications - help! :(

Cliff Yamamoto cyamamot at castor.usc.edu
Sat Jun 17 00:34:45 AEST 1989


Hello

	I'm trying to write a program which can monitor the values of the
numerical variables of another program in "almost" real-time.  I've looked
into 'ptrace' and shared memory but I think I'd like to use sockets.

	My problem is just trying to get a darn socket-demo program to
work.  I'm using an example from "The Design of the Unix Operating System"
by Maurice J. Bach - AT&T press pp. 383.

Some questions :

Is the 'server' supposed to run in background/foreground?
Is the 'client' supposed to run in background/foreground?
(In general, how are what needs to be done to run the 'server' and 'client'?)

>>>> Can someone *please* send my any kind of working 'socket' demo between
     two processes? (we're using BSD 4.3 on Sun 3/260s - Sun OS 4.0) <<<<

I'm not sure if my programs are faulty or if the way I'm trying to execute
them is faulty.  If someone thinks there is a better way to go than using
sockets, please let my know.  But is must be portable, so I can't use Sun's
dbx or dbxtools and ptrace can't handle forks within a program and shared
memory seems to imply shared variable types, which my monitor program and
target program obviously won't have.

Thanks again!!
Cliff Yamamoto



More information about the Comp.unix.questions mailing list