From owner-freebsd-questions@FreeBSD.ORG Thu Jun 19 13:22:26 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6C63337B401 for ; Thu, 19 Jun 2003 13:22:26 -0700 (PDT) Received: from sccrmhc13.attbi.com (sccrmhc13.comcast.net [204.127.202.64]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8D96243FA3 for ; Thu, 19 Jun 2003 13:22:25 -0700 (PDT) (envelope-from freebsd-questions-local@be-well.no-ip.com) Received: from be-well.ilk.org (be-well.no-ip.com[24.147.188.198]) by attbi.com (sccrmhc13) with ESMTP id <20030619202224016001l0sie>; Thu, 19 Jun 2003 20:22:24 +0000 Received: from be-well.ilk.org (lowellg.ne.client2.attbi.com [24.147.188.198] (may be forged)) by be-well.ilk.org (8.12.9/8.12.7) with ESMTP id h5JKMO1V011220; Thu, 19 Jun 2003 16:22:24 -0400 (EDT) (envelope-from freebsd-questions-local@be-well.no-ip.com) Received: (from lowell@localhost) by be-well.ilk.org (8.12.9/8.12.6/Submit) id h5JKMKf3011217; Thu, 19 Jun 2003 16:22:20 -0400 (EDT) X-Authentication-Warning: be-well.ilk.org: lowell set sender to freebsd-questions-local@be-well.ilk.org using -f Sender: lowell@be-well.no-ip.com To: Supote Leelasupphakorn References: <20030619064639.55561.qmail@web40601.mail.yahoo.com> From: Lowell Gilbert Date: 19 Jun 2003 16:22:20 -0400 In-Reply-To: <20030619064639.55561.qmail@web40601.mail.yahoo.com> Message-ID: <44u1alhl6r.fsf@be-well.ilk.org> Lines: 29 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii cc: jez.hancock@munk.nu cc: freebsd-questions@freebsd.org Subject: Re: what dose the command "chflags" used for ? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jun 2003 20:22:26 -0000 Supote Leelasupphakorn writes: > >> Dear all, > >> > >> Because we have the command "chmod" for change > the > >> permissions of > >> files so what does the command "chflags" used for > and > >> what suituation > >> I must use it ? > > >chflags is used to set system flags on files you > don't want to be > >modified accidentally - most commonly the 'noschg' > flag stops a file > >from being deleted by a normal user. > > >See the man page for more details, and also the -o > option to 'ls' (which > >shows flag settings for files. > > but "chmod 600 do the same thing why does > "chflags" come to play ? Flags can't be removed (at all) under raised securelevels. Most of the flags have semantics that can't fully be duplicated with normal file permissions.