Fixing install (Was: Re: [Fwd: How To Recover From Missing /lib/libc.so.7?])

From: Mel Flynn <mel.flynn+fbsd.current_at_mailing.thruhere.net>
Date: Fri, 7 Aug 2009 16:02:59 -0800
On Friday 07 August 2009 11:14:54 Ed Schouten wrote:
> * Ed Schouten <ed_at_80386.nl> wrote:
> > * Chris Ruiz <yr.retarded_at_gmail.com> wrote:
> > > You must specify NO_FSCHG= when you installworld on an unupgraded ZFS
> > > filesystem, otherwise you will lose libc.so.7!  I'll spare you the
> > > details on why this happens.
> >
> > Which is because our install(1) is stupid enough to delete the resulting
> > binary if it can't add the schg flag. We should really change this
> > behaviour.
>
> It looks like there are actually two bugs:
>
> - install(1) does check for EOPNOTSUPP, while ZFS seems to return
>   EINVAL. This is probably a ZFS bug.
> - Inside jails, (un)setting schg is not permitted and returns EPERM. We
>   should change the VFS to return EOPNOTSUPP or install(1) to allow
>   EPERM as well.
>
> It's a bit late, but I think it would be nice to have this fixed before
> 8.0.

Perhaps the second case only if jailed? EPERM is also given when the running 
user doesn't have permission and I'd rather have things bail out sooner then 
later. Patch attached for this.
-- 
Mel

Received on Fri Aug 07 2009 - 22:03:01 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:53 UTC