On Tue, 2005-08-23 at 17:23 +1000, Badai Aqrandista wrote:
> How do I maintain the size of the shared memory between apache children?
> What cause a memory page to be copied (not shared) from perl's point of
> view?
Anything that writes to memory -- modifying any variable (even just
reading one in a different context) or compiling some code are the most
common things. There's a bit more here:
http://modperlbook.com/html/ch10_01.html
Oh my, I should've kept memory consumption in mind when designing the code
in the first place.
Anyway, to fix this, I'm trying to make my onw shared memory with
Apache::SharedMem. But it seems that shared memory is just a memory area
that any process can read from or write to, not a memory that can become
part of any process's memory space.
I'd like to put the read only data in a memory area that can become part of
any process's memory space, like threads sharing memory space. Is there any
way I can do that? How about mmap? I have never looked into that.
Does this sound like fixing the wrong problem?
Thank you...
---
Badai Aqrandista
Cheepy (?)
_________________________________________________________________
On the road to retirement? Check out MSN Life Events for advice on how to
get there! http://lifeevents.msn.com/category.aspx?cid=Retirement