From owner-freebsd-questions@FreeBSD.ORG Fri Jun 10 21:07:36 2005 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 6F85716A41C for ; Fri, 10 Jun 2005 21:07:36 +0000 (GMT) (envelope-from freebsd@philip.pjkh.com) Received: from zhonka1.zhonka.net (zhonka1.zhonka.net [66.228.195.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2E0F643D1D for ; Fri, 10 Jun 2005 21:07:35 +0000 (GMT) (envelope-from freebsd@philip.pjkh.com) Received: from wolf.pjkh.com ([66.228.196.74]) by zhonka1.zhonka.net (Post.Office MTA v3.5.3 release 223 ID# 0-58414U4500L450S0V35) with ESMTP id net; Fri, 10 Jun 2005 14:07:35 -0700 Received: from localhost (localhost [127.0.0.1]) by wolf.pjkh.com (Postfix) with ESMTP id C6A6F58C7; Fri, 10 Jun 2005 14:07:28 -0700 (PDT) Received: from wolf.pjkh.com ([127.0.0.1]) by localhost (wolf.pjkh.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 22549-03; Fri, 10 Jun 2005 14:07:28 -0700 (PDT) Received: by wolf.pjkh.com (Postfix, from userid 1000) id 91BF158C6; Fri, 10 Jun 2005 14:07:28 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by wolf.pjkh.com (Postfix) with ESMTP id 8D3485823; Fri, 10 Jun 2005 14:07:28 -0700 (PDT) Date: Fri, 10 Jun 2005 14:07:28 -0700 (PDT) From: Philip Hallstrom To: Tony Shadwick In-Reply-To: <20050610142559.S78603@mail.goinet.com> Message-ID: <20050610140427.H22656@wolf.pjkh.com> References: <20050610142559.S78603@mail.goinet.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by amavisd-new at pjkh.com Cc: freebsd-questions@freebsd.org Subject: Re: system cloning 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: Fri, 10 Jun 2005 21:07:36 -0000 > Here's my scenario: > > I have a system that we are running in production that there was an oversight > on, and it has a single hard drive installed (32GB SCSI I believe), rather > than a 3 drive raid5 array. We would like to correct this, but we have all > sorts of up-to-date packages and config files that we've tweaked that we > would hate to just start over on it. > > There's a tool for OSX called "Carbon Copy Cloner" that would take care of > this for me, which is basically a series of copy commands that takes the > filesystem from one drive to another, preserving EVERYTHING important, and > then bless the boot volume. > > Is there anything similar I can do on FreeBSD? My boss thinks I should be > able to tar up the entire filesystem, create the raid array, and untar the > whole thing on the new array. I seem to think this will fail due to block > devices that have changed, fstab entries that have changed (though this is > correctable), and symlinks that don't nicely come across. Not that I do this a lot, but I think you'll run into problems using tar, cp, and rsync when it comes to various special files or files with holes in them (sparse files). I've always read that dump/restore is the safest way to do something like this. When I have done it, I boot off of a live CD on the server in question. Then somewhere else I have an NFS server running. Mount the share on your live CD box. dump each partition to the share. Then install the new hard disks... Then boot the box off the live cd again, mount the share, do whatever fdisk'ing and disklabel'ing and newfs'ing is necessary to get the partitions you want and restore each of the dumps (in the right order of course). It's worked for me... -philip