From owner-freebsd-questions@FreeBSD.ORG Wed Feb 6 05:45:42 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 004FF16A417 for ; Wed, 6 Feb 2008 05:45:41 +0000 (UTC) (envelope-from francois-xavier@charpentier-de-beauville.com) Received: from vms048pub.verizon.net (vms048pub.verizon.net [206.46.252.48]) by mx1.freebsd.org (Postfix) with ESMTP id E95B013C467 for ; Wed, 6 Feb 2008 05:45:41 +0000 (UTC) (envelope-from francois-xavier@charpentier-de-beauville.com) Received: from [127.0.0.1] ([70.107.210.24]) by vms048.mailsrvcs.net (Sun Java System Messaging Server 6.2-6.01 (built Apr 3 2006)) with ESMTPA id <0JVS00D8GYMPOEO5@vms048.mailsrvcs.net> for freebsd-questions@freebsd.org; Tue, 05 Feb 2008 23:44:50 -0600 (CST) Date: Wed, 06 Feb 2008 00:44:49 -0500 From: Francois-Xavier Charpentier de Beauville In-reply-to: <20080205091416.D1594@wojtek.tensor.gdynia.pl> To: Wojciech Puchar Message-id: <47A94951.70605@charpentier-de-beauville.com> MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7bit References: <47A7D343.1090603@charpentier-de-beauville.com> <20080205091416.D1594@wojtek.tensor.gdynia.pl> User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) Cc: 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 Reply-To: francois-xavier@charpentier-de-beauville.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Feb 2008 05:45:42 -0000 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?