From owner-freebsd-questions@FreeBSD.ORG Sun Nov 11 21:21:57 2007 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 640B116A418 for ; Sun, 11 Nov 2007 21:21:57 +0000 (UTC) (envelope-from jrisom@gmail.com) Received: from py-out-1112.google.com (py-out-1112.google.com [64.233.166.180]) by mx1.freebsd.org (Postfix) with ESMTP id 1824713C48D for ; Sun, 11 Nov 2007 21:21:50 +0000 (UTC) (envelope-from jrisom@gmail.com) Received: by py-out-1112.google.com with SMTP id u77so881008pyb for ; Sun, 11 Nov 2007 13:21:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:in-reply-to:references:mime-version:content-type:message-id:content-transfer-encoding:cc:from:subject:date:to:x-mailer; bh=JmmUNmfj0OJsUMMuXI1VndoN1KfsJR5Vs1AoulomRoo=; b=gZM+lcPZn9RoAluG1XFRp1wiIdV6tKsHBu75C9m3lK/h7ykbEvhCpy+rKOAyYM5EMD8RSdchtxiQVF+ym1A2iM3XwoiCf3uHKg3Jl2Z+NfBlTa3BK8NLNCGs2XEzDb74k1wRwWOPheL5OTfsfOCbpplYEwTgVN8TB9ODfmvAHAU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:in-reply-to:references:mime-version:content-type:message-id:content-transfer-encoding:cc:from:subject:date:to:x-mailer; b=LbKTyKQS2AG0vHVCc+ho88Lk3xTicFdaQi+KTYdymExzJmoKqpKcs5DnPadEp2zef5/Nr5mq1rT24uKeqJUfiJA3YvpHuZo6LzqQUP3gQEG8K/YZ9vfBmqsefO3dQYaCicvwQGF1eZPtbTSPaYMldhWNisfzgLL447IjY2NmOQQ= Received: by 10.35.12.10 with SMTP id p10mr5198338pyi.1194816098510; Sun, 11 Nov 2007 13:21:38 -0800 (PST) Received: from ?192.168.1.4? ( [74.134.230.123]) by mx.google.com with ESMTPS id f45sm8663001pyh.2007.11.11.13.21.35 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 11 Nov 2007 13:21:36 -0800 (PST) In-Reply-To: <53B52415C756A84E8A169F0E3673A3298B3A4E@IMCSRV6.MITRE.ORG> References: <9a7b572639178c625b2a6d282db16eec@gmail.com> <53B52415C756A84E8A169F0E3673A3298B3A4E@IMCSRV6.MITRE.ORG> Mime-Version: 1.0 (Apple Message framework v624) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <2f0c1f27f3e05fef09f3569d1146d025@gmail.com> Content-Transfer-Encoding: 7bit From: Joshua Isom Date: Sun, 11 Nov 2007 15:21:36 -0600 To: "Andresen, Jason R." X-Mailer: Apple Mail (2.624) Cc: freebsd-questions Questions Subject: Re: SATA DVD speed's too slow (Modified by Joshua Isom) 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: Sun, 11 Nov 2007 21:21:57 -0000 On Nov 11, 2007, at 1:20 PM, Andresen, Jason R. wrote: > From: owner-freebsd-hackers@freebsd.org > [mailto:owner-freebsd-hackers@freebsd.org] On Behalf Of Joshua Isom >> >> Redirected from freebsd-questions after no reply. >> >> I currently have an SATA DVD-RW drive for my computer. I have to boot > >> using a CURRENT kernel to get the drive recognized, and dmesg lists it > >> as running at 3.3MB/s. Running mplayer -dumpstream gets around 3 megs > >> a second. Copying off a data dvd gets about the same. But I recall >> reading about playing a dvd before trying to get the data off of it >> when using dd, and it seems to work. But the odd part is, it can get >> up to 20 megabytes a second. Does anyone know how to get the higher >> speeds all the time? > > What you're probably seeing is a feature of how modern optical drives > work. Unlike the "4x" drives of old, the drive does not speed up or > slow down the disc based on the position of the head, instead they > maintain a fixed rotation speed. Because of this, the pits on the edge > of the disc move much faster than the ones near the center of the disc. > As you write to the disc you will see your speed increase as the laser > gets closer to the edge. Of course the drive manufacturers advertise > the speed of reading/writing the outermost track when selling the > drive. > I think you don't really notice some of the details. The kernel says the drive is only capable of 3.3M/s. Mplayer can dump a dvd at around 3.0M/s. If I "play" the dvd a little bit(just a few seconds), and then use dd to dump it, I can achieve three times the speed that the kernel says is possible. If I mount as UDF, I get around 3.0M/s. If I mount as cd9660, I get the higher speeds. I believe it is largely due to block size(too much time spent on read calls and protocols than reading data, as the speed can quickly triple when the reads are cut down to 10% of what they were). It seems to me as though the fastest ways for FreeBSD to copy DVD are to use dd or mount_cd9660, or else wait an excruciatingly long time. But, the drive is getting speeds far faster than the kernel lists it as capable of, and in gstat not even listing it as 100% busy. Here's a quick snapshot of gstat, using cp -R with the dvd mounted as cd9660. dT: 1.002s w: 1.000s filter: ^[a-z]+[0-9]+$ L(q) ops/s r/s kBps ms/r w/s kBps ms/w %busy Name 0 0 0 0 0.0 0 0 0.0 0.0| ad0 0 0 0 0 0.0 0 0 0.0 0.0| cd0 0 0 0 0 0.0 0 0 0.0 0.0| acd0 0 126 0 0 0.0 126 16096 1.6 19.9| ad4 0 0 0 0 0.0 0 0 0.0 0.0| cd1 1 250 250 15968 3.5 0 0 0.0 87.3| acd1 The drive is reading five times faster than I can achieve with mplayer or a udf filesystem, and five times faster than the kernel says is possible. Is the drive initially lieing about it's speed and somehow sending an updated speed that's not being reported? Here's the product page for the drive. http://www.liteonit.com/global/index.php? option=com_content&task=view&id=199&Itemid=67