public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Joshua Murphy <poisonbl@gmail.com>
To: gentoo-user <gentoo-user@lists.gentoo.org>
Subject: Re: [gentoo-user] Re: dd - bytes at a time
Date: Sun, 20 Dec 2009 22:39:01 -0500	[thread overview]
Message-ID: <c30988c30912201939saae475bu8b594b7704d526fd@mail.gmail.com> (raw)
In-Reply-To: <20091219151545.500abcf4@digimed.co.uk>

On Sat, Dec 19, 2009 at 10:15 AM, Neil Bothwick <neil@digimed.co.uk> wrote:
> On Sat, 19 Dec 2009 12:11:27 +0000, Stroller wrote:
>
>> > Incidentally, if you want to use dd, adding bs=4096 speeds it up quite
>> > significantly.
>>
>> Thank you. I have always wondered what the optimal bs might be.
>> And why - could you possibly explain that, please?
>>
>> Is bs=4096 best for all disk-based operations?
>
> Many filesystems are set up with 4K blocks, so matching this with dd is
> more efficient. The default is 512 byte blocks and anything larger
> than this is good, I sometimes use 40960 but that isn't significantly
> faster. I prefer to avoid using dd on hard disks altogether, it's just
> so damn slow for large amounts of data.
>
>
> --
> Neil Bothwick
>
> You can't teach a new mouse old clicks.
>

My *completely uneducated* guess would be that, for a raw disk level
copy (on a normal spinning disk) or write a bs that is *at the least*
divisible into the drive's cache size, and at best *is* the drive's
cache size, would be best. For SSDs, if you have some strange reason
to need to use dd with one (I'd avoid it simply because a: you'll
never guarantee an overwrite of what's really there now and b: you'll
be put at least a small dent in the lifespan of the drive) the minimum
erase block size would be best, since that'd allow both a full erase
and a full write of a block, rather than risking 2 erases to get all
of one block written.

I do reiterate that this is all mere conjecture, and is based in my
likely flawed conceptual understanding of the drives.

-- 
Poison [BLX]
Joshua M. Murphy



  reply	other threads:[~2009-12-21  4:03 UTC|newest]

Thread overview: 67+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-16 18:49 [gentoo-user] {OT} Preparing a laptop for sale Grant
2009-12-16 19:06 ` Neil Bothwick
2009-12-16 19:24 ` Mick
2009-12-16 21:25   ` Albert Hopkins
2009-12-16 23:24   ` Marcus Wanner
2009-12-17 11:23     ` Mick
2009-12-16 23:36   ` Dale
2009-12-17  0:37     ` Robert Bridge
2009-12-17  8:13       ` Alan McKinnon
2009-12-17  9:52         ` Adam
2009-12-17 15:12         ` Alex Schuster
2009-12-17 15:19           ` Nevynxxx
2009-12-17 15:35         ` Robert Bridge
2009-12-17  0:56     ` Joshua Murphy
2009-12-17  2:49       ` Dale
2009-12-17  5:13         ` Joshua Murphy
2009-12-17 11:42           ` Mick
2009-12-17 12:47             ` Albert Hopkins
2009-12-19  9:39               ` Mick
2009-12-17 13:40             ` Marcus Wanner
2009-12-17 14:26               ` Neil Bothwick
2009-12-17 16:49                 ` Alan McKinnon
2009-12-17 22:09                   ` Neil Bothwick
2009-12-17 23:15                     ` BRM
2009-12-17 19:29               ` Stroller
2009-12-16 19:54 ` Robert Bridge
2009-12-18 17:08   ` Grant
2009-12-18 18:20     ` Dale
2009-12-18 18:30       ` Grant
2009-12-18 20:09       ` Albert Hopkins
2009-12-18 18:28     ` Joshua Murphy
2009-12-18 23:05       ` Grant
2009-12-19  0:23         ` Dale
2009-12-19  0:32         ` Albert Hopkins
2009-12-19  1:51         ` Marcus Wanner
2009-12-19  1:58           ` Grant
2009-12-19 10:59             ` Neil Bothwick
2009-12-19 12:11               ` [gentoo-user] Re: dd - bytes at a time Stroller
2009-12-19 15:15                 ` Neil Bothwick
2009-12-21  3:39                   ` Joshua Murphy [this message]
2009-12-19 16:50               ` [gentoo-user] {OT} Preparing a laptop for sale Grant
2009-12-19 18:47                 ` Albert Hopkins
2009-12-19 22:57                   ` Grant
2009-12-20 21:56                   ` Grant
2009-12-20 23:30                     ` Willie Wong
2009-12-21 17:01                       ` Grant
2009-12-21 18:31                         ` Willie Wong
2009-12-21 19:38                           ` Dale
2009-12-21 20:06                             ` Grant
2009-12-21 22:28                               ` Dale
2009-12-22 23:10                               ` Willie Wong
2009-12-22 23:08                                 ` Grant
2010-01-10 11:36                             ` [gentoo-user] coreutils compilation fail Li
2010-01-10 12:39                               ` Arttu V.
2009-12-21 20:03                           ` [gentoo-user] {OT} Preparing a laptop for sale Grant
2009-12-22  2:59                             ` Grant
2009-12-22  7:14                               ` Alan McKinnon
2009-12-22 18:34                               ` Grant
2009-12-21 22:18                           ` Neil Bothwick
2009-12-22 13:04                             ` John H. Moe
2009-12-22 15:41                               ` Neil Bothwick
2009-12-22 23:14                                 ` Willie Wong
2009-12-19 16:46             ` Marcus Wanner
2009-12-18 20:08     ` Albert Hopkins
2009-12-16 19:58 ` John Lowry
2009-12-16 21:12 ` Dan Cowsill
     [not found] ` <c30988c30912161202n79a212ecx734336b46ec9e990@mail.gmail.com>
2009-12-17 15:51   ` Alex Schuster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c30988c30912201939saae475bu8b594b7704d526fd@mail.gmail.com \
    --to=poisonbl@gmail.com \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox