Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Use dd to benchmark drives

    Hi all,

    I'm trying to test the durability of solid state drives. My goal is to see how many read/write cycles a drive can support and how the performance changes with each cycle. I am using the dd command to first zero-out the drive and then fill it with random data. So far I have:

    #Arg 1: Drive directory
    #Arg 2: Number of desired cycles
    for (( n=1; n<=$2; n++))
        echo "Iteration $n"
        dd if=/dev/zero    of=$1 bs=1M conv=notrunc
        dd if=/dev/urandom of=$1 bs=1M conv=notrunc
    exit 0
    I want to changes this to do two things:
    1. Instead of writing random data in the second step, I want to write all 1's to the drive. This way, every bit is switched from 0 to 1 each time i execute these commands.

    2. Save the outputs to a text file so that I can see the performance changes over time.

    I have been using
    http: //ww
    as a reference.

    I would appreciate any help on this. Thanks.

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Is this work work, or school work?
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Quote Originally Posted by Rubberman View Post
    Is this work work, or school work?
    School work. I would know better than to post work work code (even tho this is incredibly basic stuff and is found on other forums) Is there a difference?

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts