Received: from PACIFIC-CARRIER-ANNEX.MIT.EDU by po7.MIT.EDU (5.61/4.7) id AA20787; Mon, 11 Mar 96 23:37:44 EST
Received: from macgyver.pr.mcs.net by MIT.EDU with SMTP
	id AA03928; Mon, 11 Mar 96 23:36:59 EST
Received: (from macgyver@localhost) by starbase.tos.net (8.7.5/8.7.3) id WAA13734; Mon, 11 Mar 1996 22:37:33 -0600
Date: Mon, 11 Mar 1996 22:37:32 -0600 (CST)
From: MacGyver <macgyver@tos.net>
To: proven@MIT.EDU
Subject: Quick question...
Message-Id: <Pine.LNX.3.91.960311222856.143D-100000@starbase.tos.net>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII

Actually, I have two questions...the first is that I noticed in the 
pthreads WWW pages that the latest version was 1.60 beta 5, and the 
latest I could find was beta 4_1...where can I get the latest?

Second...how does fork() interact with pthreads?  Here's specifically 
what I'm doing...

An application I have needs to save information to disk that's getting 
updated constantly.  I fork off a process and then write the data to 
disk, without needing to worry about some of that data being updated 
while I'm trying to write it to disk which would cause the data to become 
inconsistent.  The parent process just keeps going, handling requests and 
modifying the data in memory, so we've effectively saved a 'snapshot' of 
the data by executing the fork and then having it write to disk.  This 
database that gets written can become very large, on the order of several 
megs.  My question is, will fork() handle this condition properly?  I 
noticed in the pthreads mailing list archive a discussion on fork() and 
from what I gathered, it wouldn't be handled properly.  Actually, I'd 
love to be able to move this whole thing to threads completely, 
eliminating the need for fork() at all, but I need to satisfy the two 
conditions that 1) I can't afford to block for any long length of time to 
save the state of the data (ie I need to always be capable of handling 
requests), and 2) the data must be in a consistent state.  That is, I 
can't start writing the data to disk, then modify *ANY* part of it until 
it's saved.

I'd really appreciate any input or information you could share with me on 
this.  Thanks.

HJD.

