dd - unequal speed from partition to partition, partition to file,file to partition

Discussion in 'C Programming' started by bolega, Mar 28, 2011.

  1. bolega

    bolega Guest

    dd - unequal speed from partition to partition, partition to file,
    file to partition

    /dev/sda1 to /dev/sda2 around 25Meg/s
    /dev/sda1 to a file_sda1 around 12Meg/s
    file_sda1 to /dev/sda1 around 5Meg/s

    Why ???

    I have played with various block sizes such 1M, 4M, 500M

    In the all three cases, its from the same disk to itself OR from
    different disks, eg SATA to USB ... if I recall correctly.

    Please give an explanation why read from a file to disk partition is
    so slow ???

    Bolega
    bolega, Mar 28, 2011
    #1
    1. Advertising

  2. bolega

    Stan Bischof Guest

    Re: dd - unequal speed from partition to partition, partition to file, file to partition

    In comp.os.linux.misc bolega <> wrote:
    > dd - unequal speed from partition to partition, partition to file,
    > file to partition
    >
    > /dev/sda1 to /dev/sda2 around 25Meg/s
    > /dev/sda1 to a file_sda1 around 12Meg/s
    > file_sda1 to /dev/sda1 around 5Meg/s
    >
    > Why ???
    >
    > I have played with various block sizes such 1M, 4M, 500M
    >
    > In the all three cases, its from the same disk to itself OR from
    > different disks, eg SATA to USB ... if I recall correctly.
    >
    > Please give an explanation why read from a file to disk partition is
    > so slow ???
    >


    Well, the obvious answer ( maybe even the right one ! ) is that
    different disks and interfaces have different speeds available,
    different cache sizes and so on.

    Transferrring from one SATA disk to another SATA on the same bus
    will definitely be a different speed than transferring from the
    same disk to another disk mounted on USB. Transferring from one
    disk to another will be different ( likely faster ) than
    from one disk to elsewhere on the same disk.

    In each case the data goes through a path- and the slowest
    link in that path will determine the overall speed. Then
    you get into other items like cache size- small files may be very
    fast if they fit into cache while big files can be much
    slower since they overflow the cache. Lots of variables.

    There is absolutely no reason to expect the various paths
    to be the same speed , not even taking into account the
    software used.

    Stan
    Stan Bischof, Mar 28, 2011
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Raistlin

    Comparing 2 unequal arrays...

    Raistlin, Sep 28, 2003, in forum: C++
    Replies:
    6
    Views:
    799
    Ron Natalie
    Sep 29, 2003
  2. Replies:
    1
    Views:
    547
    christian.bau
    Jan 15, 2007
  3. Unequal Length Maze

    , Aug 24, 2007, in forum: Python
    Replies:
    3
    Views:
    339
    Diez B. Roggisch
    Aug 24, 2007
  4. Peter Otten
    Replies:
    3
    Views:
    268
    Peter Otten
    Jan 29, 2010
  5. Ganesh Gopalakrishnan
    Replies:
    1
    Views:
    134
    Ganesh Gopalakrishnan
    Oct 17, 2011
Loading...

Share This Page