Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
* Tru64 5.1a msync causes corrupt files (sometimes)
@ 2003-06-19  2:25 Jake Stoll
  2003-07-02  7:35 ` Jake Stoll
  0 siblings, 1 reply; 2+ messages in thread
From: Jake Stoll @ 2003-06-19  2:25 UTC (permalink / raw)


Hi All,

I've experienced a situation using the c function msync() where the
function returns successfully but the file being mapped has been
corrupted (file changed but extra bytes set to zero). This doesn't
happen everytime it varies from 1 in 5 times to 2 out of 3 times.

Has anyone seen this behaviour before?
I've tried changing some(most) of the dynamic kernel options using the
kernel tuner and recompiled the kernel with various options, tried the
mapped file on advfs and ufs, applied the latest accumulative patch
kit, searching for similar problems, to no avail...

Am I sure that it's the msync() function?
Yes. Using ladebug and confirming that what's in the mapped memory is
ok, as soon as the msync function returns the file is either corrupt
or good.

What does the application do?
In my test case (approximately);
 creates a private memory map of files A,B,C which are about 5MB in
size
 modifies a couple of the private memory maps (e.g A & B)
  creates a shared memory map for A
  bcopy's the modified private map to the shared map for A
  msync shared map A
  munmap shared map A
  munmap private map A
 repeat for other modified private maps

Any help, suggestions or comments would be greatly appreciated.

Regards,
Jake.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Tru64 5.1a msync causes corrupt files (sometimes)
  2003-06-19  2:25 Tru64 5.1a msync causes corrupt files (sometimes) Jake Stoll
@ 2003-07-02  7:35 ` Jake Stoll
  0 siblings, 0 replies; 2+ messages in thread
From: Jake Stoll @ 2003-07-02  7:35 UTC (permalink / raw)


So, judging from the response I guess no-one has run into a similar problem...

Is there a more appropriate forum for such a question?

Regards,
Jake.

jake.stoll@logicacmg.com (Jake Stoll) wrote in message news:<369fc9fe.0306181825.697f79cd@posting.google.com>...
> Hi All,
> 
> I've experienced a situation using the c function msync() where the
> function returns successfully but the file being mapped has been
> corrupted (file changed but extra bytes set to zero). This doesn't
> happen everytime it varies from 1 in 5 times to 2 out of 3 times.
> 
> Has anyone seen this behaviour before?
> I've tried changing some(most) of the dynamic kernel options using the
> kernel tuner and recompiled the kernel with various options, tried the
> mapped file on advfs and ufs, applied the latest accumulative patch
> kit, searching for similar problems, to no avail...
> 
> Am I sure that it's the msync() function?
> Yes. Using ladebug and confirming that what's in the mapped memory is
> ok, as soon as the msync function returns the file is either corrupt
> or good.
> 
> What does the application do?
> In my test case (approximately);
>  creates a private memory map of files A,B,C which are about 5MB in
> size
>  modifies a couple of the private memory maps (e.g A & B)
>   creates a shared memory map for A
>   bcopy's the modified private map to the shared map for A
>   msync shared map A
>   munmap shared map A
>   munmap private map A
>  repeat for other modified private maps
> 
> Any help, suggestions or comments would be greatly appreciated.
> 
> Regards,
> Jake.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-07-02  7:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-19  2:25 Tru64 5.1a msync causes corrupt files (sometimes) Jake Stoll
2003-07-02  7:35 ` Jake Stoll

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox