From owner-freebsd-usb@FreeBSD.ORG Thu Dec 8 09:13:14 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6AF45106564A for ; Thu, 8 Dec 2011 09:13:14 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe09.c2i.net [212.247.155.2]) by mx1.freebsd.org (Postfix) with ESMTP id BF8608FC0C for ; Thu, 8 Dec 2011 09:13:13 +0000 (UTC) X-T2-Spam-Status: No, hits=-0.2 required=5.0 tests=ALL_TRUSTED, BAYES_50 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe09.swip.net (CommuniGate Pro SMTP 5.4.2) with ESMTPA id 39706571; Thu, 08 Dec 2011 10:13:10 +0100 From: Hans Petter Selasky To: freebsd-usb@freebsd.org, Matthias Apitz Date: Thu, 8 Dec 2011 10:10:36 +0100 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <20111208063711.GA6482@tinyCurrent> In-Reply-To: <20111208063711.GA6482@tinyCurrent> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq, NwSZ4V"|LR.+tj}g5 %V,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( :AuzV9:.hESm-x4h240C`9=w MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201112081010.36695.hselasky@c2i.net> Cc: freebsd-questions@freebsd.org Subject: Re: restore(8) to UFS on USB key: terrible slow X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Dec 2011 09:13:14 -0000 On Thursday 08 December 2011 07:37:12 Matthias Apitz wrote: > Hello, > > I encounter the following problem with UFS file systems on USB keys, > i.e. the problem is not only with one key, but with all I have; the key > in question here is: > > Dec 7 22:17:47 tinyCurrent kernel: umass0: 0/0, rev 2.00/1.02, addr 3> on usbus4 Dec 7 22:17:47 tinyCurrent kernel: > umass0: SCSI over Bulk-Only; quirks = 0x4101 Dec 7 22:17:47 tinyCurrent > root: Unknown USB device: vendor 0x058f product 0x6387 bus uhub4 Dec 7 > 22:17:48 tinyCurrent kernel: umass0:0:0:-1: Attached to scbus0 Dec 7 > 22:17:48 tinyCurrent kernel: da0 at umass-sim0 bus 0 scbus0 target 0 lun 0 > Dec 7 22:17:48 tinyCurrent kernel: da0: > Removable Direct Access SCSI-2 device Dec 7 22:17:48 tinyCurrent kernel: > da0: 40.000MB/s transfers > Dec 7 22:17:48 tinyCurrent kernel: da0: 7650MB (15667200 512 byte sectors: > 255H 63S/T 975C) > > and the system is: > > $ uname -a > FreeBSD tinyCurrent 9.0-CURRENT FreeBSD 9.0-CURRENT #1 r214444: Thu Oct 28 > 10:56:32 CEST 2010 > > The key was formatted the usual way for receiving a complete FreeBSD > system for installation purpose: > > # fdisk -I da0 > # fdisk -B da0 > # bsdlabel -w da0s1 auto > # bsdlabel -B da0s1 > # bsdlabel -e da0s1 > # newfs /dev/da0s1a > # mount /dev/da0s1a /mnt > > When I now bulk write a big file to the file system, the write > performance is reasonable fast, even with blocks of 512 bytes, > it gives 2 MByte / sec: > > # dd if=usb.dmp of=/mnt/byte > 10926520+0 records in > 10926520+0 records out > 5594378240 bytes transferred in 2538.942585 secs (2203428 bytes/sec) > Hello! The default block size of dd is 512 bytes. Try setting bs=65536 :-) --HPS