From owner-freebsd-questions@FreeBSD.ORG Wed Feb 6 15:34:35 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1569916A419 for ; Wed, 6 Feb 2008 15:34:35 +0000 (UTC) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: from gizmo.acns.msu.edu (gizmo.acns.msu.edu [35.8.1.43]) by mx1.freebsd.org (Postfix) with ESMTP id 9E05613C46A for ; Wed, 6 Feb 2008 15:34:34 +0000 (UTC) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: from gizmo.acns.msu.edu (localhost [127.0.0.1]) by gizmo.acns.msu.edu (8.13.6/8.13.6) with ESMTP id m16FVAbZ018939; Wed, 6 Feb 2008 10:31:10 -0500 (EST) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: (from jerrymc@localhost) by gizmo.acns.msu.edu (8.13.6/8.13.6/Submit) id m16FVAcR018938; Wed, 6 Feb 2008 10:31:10 -0500 (EST) (envelope-from jerrymc) Date: Wed, 6 Feb 2008 10:31:10 -0500 From: Jerry McAllister To: Francois-Xavier Charpentier de Beauville Message-ID: <20080206153110.GA18883@gizmo.acns.msu.edu> References: <47A7D343.1090603@charpentier-de-beauville.com> <20080205091416.D1594@wojtek.tensor.gdynia.pl> <47A94951.70605@charpentier-de-beauville.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <47A94951.70605@charpentier-de-beauville.com> User-Agent: Mutt/1.4.2.2i Cc: Wojciech Puchar , freebsd-questions@freebsd.org Subject: Re: Preserving file permissions with dump and restore X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Feb 2008 15:34:35 -0000 On Wed, Feb 06, 2008 at 12:44:49AM -0500, Francois-Xavier Charpentier de Beauville wrote: > Wojciech Puchar wrote: > >>Hi, > >> > >>I have a box with three hard drives: > >>/dev/da0 - dedicated to the OS > >>/dev/ad4s1e - data drive - mounted as /store > >>/dev/ad5s1e - hold a backup of /dev/ad4 - mounted as /backup > >> > >>I used 'dump' to backup everything from /store to /backup with the > >>following command: > >>dump -0aun -f /backup/fullbackup /store > >> > >>As expected, the result is a dump file called 'fullbackup' > >> > >>Then I tested a restore, by restoring the fullbackup file from > >>/backup to /store. I did the following: > >>1) made /store pristine: newfs -U /dev/ad4s1e > >>2) mounted /dev/ad4s1e on /store > >>3) cd into /store > >>4) ran the command: restore -r -uv -f /backup/fullbackup > >>5) remove 'restoresymtable' from /store > >> > >>Thanks in advance for your help > > > >you did restore as root? (i think so but just for sure) > > > >it is something wrong with restore then, i used it many times and it > >restore everything. > > > > > >anyway - rsync is good tool to make exact copy of directory tree > > > Actually yes, I did restore as root. All ownership info and permissions > are reset during restore, and none of the original permissions are > back. This kind of weird since the OS drive hasn't changed. So, there > are the same users setup on the system. Any thoughts? Well, dump/restore should result in permissions and flags and everything being as before the dump. I have done the equivalent many many times and not seen any loss of permissions or flags or change of ownership. When the restore finished, did it ask you about setting owner/permissions on . ? If so, answer no. That is the only thing I can think of. ////jerry > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"