Skip to content

Instantly share code, notes, and snippets.

@clayg
Created July 27, 2012 17:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save clayg/3189278 to your computer and use it in GitHub Desktop.
Save clayg/3189278 to your computer and use it in GitHub Desktop.
#!/bin/bash
set -v
aptitude update &> /dev/null
DEBIAN_FRONTEND=noninteractive aptitude install mdadm -y
mdadm --create /dev/md0 --chunk=4096 --level=0 --raid-devices=5 /dev/xvd[e-i]
time dd if=/dev/md0 of=/dev/null iflag=direct bs=4096 count=10240
time dd if=/dev/md0 of=/dev/null iflag=direct bs=65536 count=640
time dd if=/dev/zero of=/dev/md0 oflag=direct bs=4096 count=10240
time dd if=/dev/zero of=/dev/md0 oflag=direct bs=65536 count=640
while !$(mdadm --stop /dev/md0); do
sleep 1
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment