From owner-freebsd-questions@FreeBSD.ORG Thu May 11 18:43:44 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 D08FD16A624 for ; Thu, 11 May 2006 18:43:44 +0000 (UTC) (envelope-from don@lizardhill.com) Received: from bigbird.whtech.com (bigbird.whtech.com [64.125.72.2]) by mx1.FreeBSD.org (Postfix) with SMTP id 91B5843E4E for ; Thu, 11 May 2006 18:08:09 +0000 (GMT) (envelope-from don@lizardhill.com) Received: (qmail 23986 invoked by uid 0); 11 May 2006 18:08:04 -0000 Received: from unknown (HELO mickey) (unknown) by unknown with SMTP; 11 May 2006 18:08:04 -0000 From: "Don O'Neil" To: "'Kevin Kinsey'" , "'Olivier Nicole'" Date: Thu, 11 May 2006 11:08:09 -0700 Message-ID: <049201c67525$dc159700$0300020a@mickey> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869 thread-index: AcZ1I/dN6VeOsxGMS9GpRy0ZhVGFjgAAN8Ug In-Reply-To: <44637A42.8030209@daleco.biz> Cc: freebsd-questions@freebsd.org Subject: RE: Copying a file system w/ tar - symbolic links not copied right. 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: Thu, 11 May 2006 18:43:48 -0000 I've tried both the BSD and GNU tars, I get the same results on both. It's very strange. When I add the B option, no different.... I used: tar cf - /array01/* | ( cd /mnt/disk01 && tar xfvBp - ) Maybe this is something specific to 4.11? Here's what happens: Source file: lrwxrwxrwx 1 root wheel 21 Feb 19 03:05 apache.log -> /var/shc/apache/logs/ Destination file created on the tar backup: ---------- 1 root wheel 0 May 11 11:02 apache.log Some have suggested using dump/restore. The problem with dump/restore is that I can't do it across the network and the file systems need to match. The whole point is to move these files/directories from one server to another to a volume with a LOT more space on a RAID array. -----Original Message----- From: Kevin Kinsey [mailto:kdk@daleco.biz] Sent: Thursday, May 11, 2006 10:54 AM To: Olivier Nicole Cc: don@lizardhill.com; freebsd-questions@freebsd.org Subject: Re: Copying a file system w/ tar - symbolic links not copied right. Olivier Nicole wrote: >> I'm trying to move a file system from one disk to another, and when >> I do >> this: > > I think that the way to go is: > > tar cf - /source/* | ( cd /destination && tar xfvBp - ) > > Note the Bp at the end of the extract tar. > > olivier Is that for BSD tar, or gtar (GNU)? We still haven't decided which is offering the problem, and I don't find "-B" described in bsdtar(1), although I can see why you'd want it in gtar, perhaps. Nonetheless, the tests I made with both tars didn't seem to have this problem. Can Don confirm whether this only occurs if /source/ is a filesystem mount point? (Also, which tar are you using?