From owner-freebsd-bugs@FreeBSD.ORG Thu May 24 20:30:24 2007 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8DC3616A4A9 for ; Thu, 24 May 2007 20:30:24 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id 7A46A13C487 for ; Thu, 24 May 2007 20:30:24 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l4OKUNjD018533 for ; Thu, 24 May 2007 20:30:23 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l4OKUNil018530; Thu, 24 May 2007 20:30:23 GMT (envelope-from gnats) Date: Thu, 24 May 2007 20:30:23 GMT Message-Id: <200705242030.l4OKUNil018530@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Nicolas Rachinsky Cc: Subject: Re: bin/39849: /sbin/restore fails to overwrite files with schg flag set X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Nicolas Rachinsky List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 May 2007 20:30:24 -0000 The following reply was made to PR bin/39849; it has been noted by GNATS. From: Nicolas Rachinsky To: cjclark@alum.mit.edu Cc: bug-followup@FreeBSD.org, mad1@tapil.com Subject: Re: bin/39849: /sbin/restore fails to overwrite files with schg flag set Date: Thu, 24 May 2007 22:23:56 +0200 * "Crist J. Clark" [2007-05-24 12:53 -0700]: > On Thu, May 24, 2007 at 02:26:21PM +0200, Nicolas Rachinsky wrote: > > >Before a restore(8) is fairly trivial. > > > > But restore does not set all the flags again. > > > > So you either have to loose some flags or some file changes if you > > restore a multi level backup. > > What flags does restore(8) not preserve? The flags of the files not touched by the following restore run. > But there still can be a problem. If you do "chflags -R", > you will lose the flag on any file that doesn't get touched > by the restore(8). These. > You could use find(1) to generate a list and then use the > list to reset the flags after. But that is a kludge. And you might preserve flags that shouldn't be preserved, since they were not during the backup (restored after the find). > An option on dump(8) to force rewriting on schg files (when > securelevel(8) allows) is probably appropriate, but as > discussed, when you start to consider directories, it becomes > non-trivial to implement. Yes. > Unfortunately, this PR is coming up on its fifth birthday > and I don't do FreeBSD work anymore. Feel free to submit > patches against a more modern CURRENT and STABLE. I noticed this problem today. And the (incomplete) patch in the PR was (kind of) rejected by you. I will try to find some time to look at this. Nicolas