From owner-freebsd-questions@FreeBSD.ORG Wed Mar 18 10:30:32 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3E4E11065674 for ; Wed, 18 Mar 2009 10:30:32 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id BC7D58FC1D for ; Wed, 18 Mar 2009 10:30:31 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1Ljt2c-0006Zx-Kc for freebsd-questions@freebsd.org; Wed, 18 Mar 2009 10:30:30 +0000 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 18 Mar 2009 10:30:30 +0000 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 18 Mar 2009 10:30:30 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Ivan Voras Date: Wed, 18 Mar 2009 11:29:51 +0100 Lines: 49 Message-ID: References: <49BF7F56.4080107@netfence.it> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig15A237CCC905DEA442CF99B3" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.19 (X11/20090105) In-Reply-To: <49BF7F56.4080107@netfence.it> X-Enigmail-Version: 0.95.0 Sender: news Subject: Re: umass performance 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: Wed, 18 Mar 2009 10:30:32 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig15A237CCC905DEA442CF99B3 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Andrea Venturoli wrote: > Hello. >=20 > I'm using dd to clone an 8GB USB memory into an identical one. >=20 >=20 >=20 > # dd if=3D/dev/da2 of=3D/dev/da1 > load: 0.01 cmd: dd 12026 [physwr] 0.00u 0.01s 0% 904k > 396+0 records in > 395+0 records out > 202240 bytes transferred in 1.453741 secs (139117 bytes/sec) > 15925248+0 records in > 15925248+0 records out > 8153726976 bytes transferred in 31722.194052 secs (257035 bytes/sec) By using this command line not only are you getting slow results, you are also probably significantly reducing the lifetime of you flash memory drive (depending on its technology). What you said in the above command line is that the copy is to be done one 512-byte block at a time - i.e. read 512 bytes, write 512 bytes, repeat. As common flash memories have large flash blocks (32 kB - 128 kB), you're actually rewriting the whole "large" flash block by writing small blocks of data. For example, to fill a 32 kB block by writing 512 bytes at a time, the whole block will be rewritten 64 times. Use a "bs=3D1m" argument next time. --------------enig15A237CCC905DEA442CF99B3 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFJwM0mldnAQVacBcgRAiadAJ9GuMT/+VOCcz46aIaQ4lA9EgIbHQCgyECV 0IvvTfkC1QsiYroGCNYxbho= =+leT -----END PGP SIGNATURE----- --------------enig15A237CCC905DEA442CF99B3--