aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2010-02-26 17:51:38 +0200
committerFilipp Lepalaan <filipp@mac.com>2010-02-26 17:51:38 +0200
commit0cd93ecedaf30247de7bbe679642819c2d8a51d1 (patch)
tree21ab2669f7b0827c7884987807b99244ead13d1b
parentd90c406d70fac8063caeeaea6718b9bdd8128643 (diff)
downloadmtk-0cd93ecedaf30247de7bbe679642819c2d8a51d1.tar.gz
mtk-0cd93ecedaf30247de7bbe679642819c2d8a51d1.tar.bz2
mtk-0cd93ecedaf30247de7bbe679642819c2d8a51d1.zip
Some fixes
-rwxr-xr-xhellyeah.command10
1 files changed, 7 insertions, 3 deletions
diff --git a/hellyeah.command b/hellyeah.command
index 574862a..2b8c692 100755
--- a/hellyeah.command
+++ b/hellyeah.command
@@ -6,6 +6,7 @@
MYDIR=/private/tmp/_hellyeah
CORES=$(sysctl hw.logicalcpu_max | cut -d : -f 2 | sed 's/ //')
+
for (( i = 0; i < ${CORES}; i++ )); do
yes > /dev/null 2>&1 &
done
@@ -14,12 +15,15 @@ if [[ ! -d "${MYDIR}" ]]; then
mkdir "${MYDIR}"
fi
-while [[ true ]]; do
+while true; do
for k in 10 100 1000 10000; do
BLOCKS=$(($k*1024/512))
- dd if=/dev/random of="${MYDIR}/$(uuidgen)" count=${BLOCKS}
+ OF="${MYDIR}/$(uuidgen)"
+ dd if=/dev/random of=${OF} count=${BLOCKS} > /dev/null 2>&1
+ sleep 2
+ echo "Wrote ${BLOCKS} blocks"
+ rm -rf "${OF}"
done
- rm -rf "${MYDIR}/*"
done
exit 0