From owner-freebsd-questions@FreeBSD.ORG Sun Mar 4 10:01:28 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ECC5416A402 for ; Sun, 4 Mar 2007 10:01:28 +0000 (UTC) (envelope-from gpeel@thenetnow.com) Received: from thenetnow.com (thenetnow.com [69.90.69.141]) by mx1.freebsd.org (Postfix) with ESMTP id C424D13C4A6 for ; Sun, 4 Mar 2007 10:01:28 +0000 (UTC) (envelope-from gpeel@thenetnow.com) Received: from hpeel.ody.ca ([216.240.12.2] helo=GRANT) by constellation.thenetnow.com with esmtpa (Exim 4.54) id 1HNnWs-00047I-4H for freebsd-questions@freebsd.org; Sun, 04 Mar 2007 05:01:22 -0500 Message-ID: <005501c75e44$1107f630$6501a8c0@GRANT> From: "Grant Peel" To: Date: Sun, 4 Mar 2007 05:01:21 -0500 Organization: The Net Now MIME-Version: 1.0 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3028 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3028 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Cloning a disk -large to small X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Grant Peel List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Mar 2007 10:01:29 -0000 Hi all, I have been researching the use of 'dd' quite a bit lately as I have had = to clone a newly setup server. The clones are done, and everything seems to be working fine.=20 I was wondering though, if one had a newly setup disk on a 74 GB SCSI = dirve, is there some know turning that can be done to clone it to a = smaller drive? Say 36 GB? Of course I ask the questing with the caveat that one of the file = systems final size (on the 36 GB disk) would of course have to suffer. So lets say we had a brand new freebsd setup on a 74 G disk swap 2GB / ufs 2 GB /usr ufs 5 GB /var ufs 5 GB /home ufs 60 GB and wanted to copy it using 'dd' to a 36 GIG drive, even though there = obviously would not be enough room for /home to be the original size? = Can 'dd' be set to truncate a fs? Can the (/home) filesystem geometry be = corrected after a regular 'dd' to the new drive? -Grant