From owner-freebsd-questions@freebsd.org Wed Aug 31 19:46:32 2016 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DE6E3BCAFD6 for ; Wed, 31 Aug 2016 19:46:32 +0000 (UTC) (envelope-from jmc-freebsd2@milibyte.co.uk) Received: from avasout08.plus.net (avasout08.plus.net [212.159.14.20]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (Client CN "Bizanga Labs SMTP Client Certificate", Issuer "Bizanga Labs CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 7B4CA199 for ; Wed, 31 Aug 2016 19:46:31 +0000 (UTC) (envelope-from jmc-freebsd2@milibyte.co.uk) Received: from curlew.milibyte.co.uk ([80.229.31.82]) by avasout08 with smtp id dvjH1t0061mJoLY01vjJ1s; Wed, 31 Aug 2016 20:43:18 +0100 X-CM-Score: 0.00 X-CNFS-Analysis: v=2.2 cv=Y6S6iVWN c=1 sm=1 tr=0 a=cd0K7rcWwnZFf6xQxRobyA==:117 a=cd0K7rcWwnZFf6xQxRobyA==:17 a=IkcTkHD0fZMA:10 a=7z1cN_iqozsA:10 a=quUobGq6AAAA:8 a=Uu_RGxbY79tbBkEIfOsA:9 a=QEXdDO2ut3YA:10 a=ALE3ELACn-YLiSo1oWt9:22 Received: from curlew.lan ([192.168.1.13] helo=milibyte.co.uk) by curlew.milibyte.co.uk with esmtp (Exim 4.87) (envelope-from ) id 1bfBPn-0002NV-K6; Wed, 31 Aug 2016 20:43:17 +0100 From: Mike Clarke To: freebsd-questions@freebsd.org Cc: "Kevin P. Neal" , "Christoph P.U. Kukulies" Date: Wed, 31 Aug 2016 20:40:36 +0100 Message-ID: <2338862.z0bWHT8yXQ@curlew.lan> User-Agent: KMail/4.14.10 (FreeBSD/10.3-RELEASE-p7; KDE/4.14.10; amd64; ; ) In-Reply-To: <20160831184925.GA80454@neutralgood.org> References: <20160831184925.GA80454@neutralgood.org> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 192.168.1.13 X-SA-Exim-Mail-From: jmc-freebsd2@milibyte.co.uk X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on curlew.lan X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham autolearn_force=no version=3.4.1 Subject: Re: dd blocksize when copying to SSD disk Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="utf-8" X-SA-Exim-Version: 4.2 X-SA-Exim-Scanned: Yes (on curlew.milibyte.co.uk) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Aug 2016 19:46:33 -0000 On Wednesday 31 Aug 2016 14:49:25 Kevin P. Neal wrote: > On Wed, Aug 31, 2016 at 06:35:28PM +0200, Christoph P.U. Kukulies wrote: > > I'm about to copy an existing Windows 7 system to an SSD. Source drive > > is a hard disk of 256 GB, destination drive a 500 GB Samsung SSD 850 EVO. > > > > > > > > Given the fact that unnecessary write operations to SSDs should be > > avoided I'm thinking about the best strategy to use dd to write to the > > SSD. > > I'm not sure that dd is the best strategy. Using Windows to do the copy > may be better. But the Windows copy command isn't very good at copying the entire system, it will fail to copy open files and certain "special" system files. On the other hand dd will copy everything in the partition but at the expense of wasting space by copying all the unused blocks. An alternative would be to use Driveimage XML from within Windows to create a compressed backup of all used blocks in the system. It's also available on a Knopixx live CD which, I think, runs it under wine so it could probably be run under wine on FreeBSD to create or restore a backup of an entire Windows partition. -- Mike Clarke