File system

Generic

Tuning

(
    set -x -e -u -o pipefail || exit 1
    test -f ./lustre.rc && . ./lustre.rc
    test -n "${FSNAME}"
    test -e "/mnt/lustre-${FSNAME}"
    test -e "/mnt/lustre-${FSNAME}/benchmarks" || sudo mkdir "/mnt/lustre-${FSNAME}/benchmarks"
    sudo lfs setstripe --count -1 --size 32M "/mnt/lustre-${FSNAME}/benchmarks"
    exit 0
)

dd

(
    set -x -e -u -o pipefail || exit 1
    test -f ./lustre.rc && . ./lustre.rc
    test -n "${FSNAME}"
    test -e "/mnt/lustre-${FSNAME}/benchmarks"
    fid="${RANDOM}"
    test ! -e "/mnt/lustre-${FSNAME}/benchmarks/dd.${fid}"
    sudo dd if=/dev/zero of="/mnt/lustre-${FSNAME}/benchmarks/dd.${fid}" bs=16M count=1024 &
    wid="${!}"
    sleep 1s
    while test -e "/proc/${wid}" ; do sudo kill -USR1 "${wid}" || true ; sleep 1s ; done &
    wait
    sudo dd if="/mnt/lustre-${FSNAME}/benchmarks/dd.${fid}" of=/dev/null bs=16M &
    rid="${!}"
    sleep 1s
    while test -e "/proc/${rid}" ; do sudo kill -USR1 "${rid}" || true ; sleep 1s ; done &
    wait
    sudo rm "/mnt/lustre-${FSNAME}/benchmarks/dd.${fid}"
    exit 0
)

Bonnie

(
    set -x -e -u -o pipefail || exit 1
    test -f ./lustre.rc && . ./lustre.rc
    test -n "${FSNAME}"
    test -e "/mnt/lustre-${FSNAME}/benchmarks"
    sudo bonnie -s 2048 -y -d "/mnt/lustre-${FSNAME}/benchmarks"
    exit 0
)

IOzone

Build

(
    set -x -e -u -o pipefail || exit 1
    mkdir ./iozone-3.327
    cd ./iozone-3.327
    wget 'http://www.iozone.org/src/current/iozone3_327.tar' -O iozone3_327.tar
    md5sum -c <<<'3b5f8d7fcb5ba5bba139165c8d53f342 *./iozone3_327.tar'
    tar -xf ./iozone3_327.tar
    cd ./iozone3_327/src/current
    make linux-AMD64
    mkdir -p /tmp/packages/iozone-3.327/bin
    cp ./iozone /tmp/packages/iozone-3.327/bin
    cd ../../../..
    rm -Rf ./iozone-3.327
    exit 0
)

Run

Network

Netperf

Build

(
    set -x -e -u -o pipefail || exit 1
    mkdir ./netperf--2.4.5
    cd ./netperf--2.4.5
    wget 'http://downloads.openwrt.org/sources/netperf-2.4.5.tar.bz2' -O netperf-2.4.5.tar.bz2
    md5sum -c <<<'5cfaae1d024551161b8eafbd48faedf4 *./netperf-2.4.5.tar.bz2'
    tar -xjf ./netperf-2.4.5.tar.bz2
    cd ./netperf-2.4.5
    ./configure --prefix=/tmp/packages/netperf--2.4.5
    make
    make install
    cd ../..
    rm -Rf ./netperf--2.4.5
    exit 0
)

Environment

Server

(
    set -x -e -u -o pipefail || exit 1
    netserver -p "${netperf_control_port}"
    exit 0
)

Client

(
    set -x -e -u -o pipefail || exit 1
    netperf \
            -t "${netperf_type}" \
            -4 -H "${netperf_server}" -p "${netperf_control_port}" \
            -l 30 -f M
    exit 0
)

Iperf

Build

(
    set -x -e -u -o pipefail || exit 1
    mkdir ./iperf--2.0.4
    cd ./iperf--2.0.4
    wget 'http://downloads.sourceforge.net/project/iperf/iperf/2.0.4%20source/iperf-2.0.4.tar.gz?use_mirror=garr' -O ./iperf-2.0.4.tar.gz
    md5sum -c <<<'8c5bc14cc2ea55f18f22afe3c23e3dcb *./iperf-2.0.4.tar.gz'
    tar -xzf ./iperf-2.0.4.tar.gz
    cd ./iperf-2.0.4
    ./configure --prefix=/tmp/packages/iperf--2.0.4
    make
    make install
    cd ../..
    rm -Rf ./iperf--2.0.4
    exit 0
)

Testing

Environment

Server

(
    set -x -e -u -o pipefail || exit 1
    iperf \
            --server --bind "${iperf_server}" --port "${iperf_port}" \
            --format MBytes --print_mss
    exit 0
)

Client

(
    set -x -e -u -o pipefail || exit 1
    iperf \
            --client "${iperf_server}" --port "${iperf_port}" \
            --time 30 --format MBytes --print_mss
    exit 0
)