From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 12 21:13:05 2006 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AF58616A41F for ; Thu, 12 Jan 2006 21:13:05 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from mail15.syd.optusnet.com.au (mail15.syd.optusnet.com.au [211.29.132.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0349F43D49 for ; Thu, 12 Jan 2006 21:13:04 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from cirb503493.alcatel.com.au (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail15.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id k0CLD0YV028897 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Fri, 13 Jan 2006 08:13:02 +1100 Received: from cirb503493.alcatel.com.au (localhost.alcatel.com.au [127.0.0.1]) by cirb503493.alcatel.com.au (8.12.10/8.12.10) with ESMTP id k0CLD0Hh013317; Fri, 13 Jan 2006 08:13:00 +1100 (EST) (envelope-from pjeremy@cirb503493.alcatel.com.au) Received: (from pjeremy@localhost) by cirb503493.alcatel.com.au (8.12.10/8.12.9/Submit) id k0CLD0Sb013316; Fri, 13 Jan 2006 08:13:00 +1100 (EST) (envelope-from pjeremy) Date: Fri, 13 Jan 2006 08:13:00 +1100 From: Peter Jeremy To: Christoph Kukulies Message-ID: <20060112211300.GB13244@cirb503493.alcatel.com.au> References: <200601120948.k0C9mcqR092895@www.kukulies.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200601120948.k0C9mcqR092895@www.kukulies.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: increasing dd disk to disk transfer rate X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Jan 2006 21:13:05 -0000 On Thu, 2006-Jan-12 10:48:38 +0100, Christoph Kukulies wrote: >dd if=/dev/ad2 of=/dev/ad3 conv=noerror > >The process is running now since yesterday evening and it is at 53 MB >at a transfer rate of about 1.1 MB/s. > >In case the the result being unusable I would like to find a way to make this >copying faster. Note that whilst increasing the DD blocksize will speed up the transfer, it will also increase the amount of collateral damage when a hard error occurs. If you rummage around the ports or tools tree, you'll find a utility (its name escapes me but I believe it was written by phk) that is designed to do disk-to-disk recovery - it copys data in big slabs until it gets an error and then works around the faulty area block by block. You should also install /usr/ports/sysutils/smartmontools - this handles S.M.A.R.T. >Is there a way to tweak the driver (be it the FreeBSD promise driver >or the normal ata driver) to use more retries on errors so that I >have the chance to copy everything or nearly everything of the already >degrading hard disk? A quick look at the ata driver suggests that there are a number of 'retry' and 'retries' variables/fields. I suspect you could increase the number of retries if you wanted to patch the driver. -- Peter Jeremy