?????????????????SSD??????MySQL???????????????????????480G SSD????RAID??240G SSD* 2 RAID0?????????????SATA??????SAS??raid10)????????
????480G SSD: INTEL SSDSC2BP480G4
????SATA:WD6401AALS-00J7B1
????240*2 SSD RAID0:  INTEL SSDSC2BP240410BTJR408108F5240AGN    RAID???? LSI MegaRAID SAS 9271-4i
????300G*4 SAS RAID10: SEAGATE ST3146855SS
????????????
????1?????????480G SSD?????????壬??2??240G SSD ??RAID????RAID0 ??????
????2?????????SSD??SATA???SAS??RAD10)????????
?????????????
????1?????sysbench mark????????????????дIO???в????
????2?????????????100G????16???????
????3????????4KB??16KB ????block size???ж?д?????
????4??????????????????д???????д???????????д??????д6??Case?????
????5????????????16??????????????180????????100000?Σ?
????????????
#!/bin/sh
device=$1
log_file=fileio.log
Usage() {
echo "basename $0 [Device Directory]"
exit 0
}
if [ -z "$*" ] || [ $# -ne 1 ]; then
Usage
fi
cd $device
for blksize in 4096 16384; do
##prepare
/usr/local/sysbench/bin/sysbench --test=fileio --file-num=16 --file-total-size=100G prepare
for mode in rndrd rndwr rndrw seqrd seqwr seqrewr; do
# for mode in seqrewr; do
echo "----$device $blksize $mode----" >> $log_file
#run
/usr/local/sysbench/bin/sysbench --test=fileio --file-num=16 --file-total-size=100G --file-test-mode=$mode --max-time=180 --max-requests=100000 --num-t
hreads=16 --init-rng=on --file-extra-flags=direct --file-fsync-freq=0 --file-block-size=$blksize run >> $log_file 2>&1
done
#cleanup
/usr/local/sysbench/bin/sysbench --test=fileio --file-total-size=100G cleanup
done
??????????1??????480G SSD??2??240 SSD??RAID0????????
????1???????
????4KB Block?????????????                     16KB Block???????240G*2 SSD(RAID0)???????
????2?????д
????4KB Block???д??480G SSD(Local)????          16KB Block???д??????????
????3???????д
????4KB Block?????д: 480G SSD(Local)????        16KB Block?????д??240G*2 SSD(RAID0)??????
????4??????
????4KB Block????: 240G*2 SSD(RAID0)????          16KB Block??????240G*2 SSD??RAID0??????
????5?????д
????4KB Block???д??480G SSD(Local)????          16KB Block???д: 480G SSD(Local)????
????6??????д
????4KB Block????д??480G SSD(Local)????        16KB Block???д??480G SSD(Local)????
???????????1??(For ????SSD??SSD??raid0??????
????1??????IO?????棺240G*2 SSD (RAID0)?????????????????????????????480G SSD(Local)????δ??2????Ч????
????2??????IOд???棺480G SSD(Local) ????д?????????240G*2 SSD (RAID0) ??