Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Oct 2000 20:48:44 -0700 (PDT)
From:      Dima Dorfman <dima@unixfreak.org>
To:        Mark Ovens <marko@freebsd.org>
Cc:        Eric Osterweil <eosterweil@hotmail.com>, questions@freebsd.org
Subject:   Re: Why does chflags cause make install to fail?
Message-ID:  <20001021034844.EEB7E1F1F@static.unixfreak.org>
In-Reply-To: <20001021014435.B258@parish> "from Mark Ovens at Oct 21, 2000 01:44:35 am"

next in thread | previous in thread | raw e-mail | index | archive | help
[ Charset ISO-8859-1 unsupported, converting... ]
> On Fri, Oct 20, 2000 at 03:41:19AM +0000, Eric Osterweil wrote:
> > 
> > 
> > I needed to recompile my kernal (to enable natd) in freeBSD 4.1.1-stable, 
> > and when I run make install I get an error telling me that the "chflags 
> > noschg /kernal" command is not allowed.  Then the "mv /kernal /kernal.old" 
> > fails and dumps the install process.
> > 
> > I cannot find any reference to this on the freeBSD.org site.  I also tried 
> > to run "chflags nouchg /kernal", but it also fails.  Is there something else 
>                   ^^^^^^
> 
> Is this a typo? it should be ``noschg''.

I think he really meant nouchg.  It shouldn't be set on /kernel, but I
guess he wanted to make sure.  He said he already tried unsetting
noschg in the previous paragraph.

> chflags(1) will only work if you are root, you are not trying to run
> it as a normal user are you?

Chflags works just fine as a normal user:

dima@lambda% id
uid=1000(dima) gid=100(users) groups=100(users), 0(wheel)
dima@lambda% touch test
dima@lambda% chflags uchg test
dima@lambda% rm -f test
rm: test: Operation not permitted
dima@lambda% chflags nouchg test
dima@lambda% rm test

You certainly can't (un)set schg as a regular user, but most flags can
be (un)set by the owner.  See `man 1 chflags` for details.

Regards

-- 
Dima Dorfman <dima@unixfreak.org>
Finger dima@unixfreak.org for my public PGP key.

"If you understand everything, you must be misinformed."
	-- Japanese Proverb


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001021034844.EEB7E1F1F>