are you going to file a kernel bug report? If so, please give us the thread 
link. also check dmesg for more information.
------Original Message------
From: Richard Matthew McCutchen
Sender: UM Linux User's Group
To: UM-LINUX@LISTSERV.UMD.EDU
ReplyTo: Richard Matthew McCutchen
Subject: Re: [UM-LINUX] ETXTBSY for shared libraries
Sent: Jun 17, 2010 2:26 AM

On Wed, 2010-06-16 at 20:25 -0400, Jacob Thompson wrote:
> On Wed, 16 Jun 2010, Richard Matthew McCutchen wrote:
> > So evidently the kernel prevents executables from being overwritten
> > while in use, but there is no analogous feature for shared libraries. [...]

> POSIX might have something to say about this.

POSIX documents the ETXTBSY behavior for executables as optional and
doesn't mention ETXTBSY for shared libraries nor MAP_DENYWRITE at all.
My understanding is that implementations are generally allowed to have
additional error cases within reason, so I don't see anything in POSIX
that would favor implementing ETXTBSY for shared libraries or not.

> Maybe there are some legitimate reasons for writing to an open shared 
> library, such as strip --strip-debug on the C library as a contrived 
> example?

I don't buy it.  The glibc web site
(http://www.gnu.org/software/libc/resources.html) says that installing
over a live system (presumably they mean without using a package
manager) is a bad idea.

-- 
Matt

Reply via email to