Re: how to make Debian less fragile (long and philosophical)
On Tue, Aug 17, 1999 at 05:52:53PM -0400, Steve Willer was heard to say:
> The problem is that the libraries aren't readonly because they in turn
> have dependencies on other libraries. During the fixup stage, the loader
> definitely has to write to those mmap'd locations. Looking quickly through
> the source shows that ldso uses MAP_PRIVATE on the mmap call. The only way
> libraries could be shared is with children, then. Forked children would
> share the page no matter what because of copy-on-write, and forked+exec'd
> children would presumably have the old mmap's clobbered.
Aah. That took me a moment but it makes sense :) However I
wonder whether this is really as bad as it sounds. This would just mean that
the pages containing locations that need to be written to would be held in
a private copy, the rest of the file could be shared as usual. How much of
a problem this is obviously depends on the particular library, but given that
most programs on my system (in a quick glance at top) claim to be sharing over
half their address space, I suspect that it may work fairly well. (I'm assuming
of course that pages which have been modified from the library image are not
listed as shared, this could be a dumb assumption)
Daniel
--
X is the second worst window system ever invented.
Everything else is tied for first.
Reply to: