Created
September 12, 2019 19:35
-
-
Save lsimmons2/0ecc1ddb98f89b824570ab2921fec058 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "INSTALLING SYSTEM DEPENDENCIES" | |
apt-get update -y | |
apt-get install -y wget build-essential git libgflags-dev libsnappy-dev zlib1g-dev libbz2-dev liblz4-dev libzstd-dev sysstat fio | |
echo "export GOMAXPROCS=128" >> ~/.bashrc | |
echo "INSTALL ROCKSDB" | |
wget https://github.com/facebook/rocksdb/archive/v5.1.4.tar.gz | |
tar -xzvf v5.1.4.tar.gz | |
cd rocksdb-5.1.4 | |
make shared_lib -d && make install-shared -d | |
ldconfig | |
echo "INSTALLING GOLANG" | |
cd | |
wget https://storage.googleapis.com/golang/go1.9.linux-amd64.tar.gz # need 1.9 for math/bits | |
tar -xvf go1.9.linux-amd64.tar.gz | |
mv go /usr/local/ | |
export PATH=$PATH:/usr/local/go/bin | |
export GOPATH=$HOME/go | |
export PATH=$PATH:$GOPATH/bin | |
echo "INSTALLING BADGER-BENCH REPO" | |
go get -t -v github.com/dgraph-io/badger-bench/... | |
cd $GOPATH/src/github.com/dgraph-io/badger-bench | |
go test # make sure stuff with rocksdb runs? | |
echo "BUILDING BADGER-BENCH COMMANDS" | |
cd populate | |
go install # build populate command | |
cd $GOPATH/src/github.com/dgraph-io/badger-bench # go back to project root to run tests | |
time populate --kv badger --valsz 64 --keys_mil 1 --dir /mnt/data/16kb | |
time go test -v --bench BenchmarkReadRandomBadger --keys_mil 1 --valsz 64 --dir "/mnt/data/16kb" --timeout 10m --benchtime 3m | |
time go test -v --bench BenchmarkIterateBadgerWithValues --keys_mil 1 --valsz 64 --dir "/mnt/data/16kb" --timeout 60m | |
time go test -v --bench BenchmarkIterateBadgerOnlyKeys --keys_mil 1 --valsz 64 --dir "/mnt/data/16kb" --timeout 60m | |
# note that inbetween running the tests of the two different stores, the state used by the stores should be cleaned | |
# I just created two different Docker containers for the different tests | |
time populate --kv bolt --valsz 64 --keys_mil 1 --dir /mnt/data/16kb | |
time go test -v --bench BenchmarkReadRandomBolt --keys_mil 1 --valsz 64 --dir "/mnt/data/16kb" --timeout 10m --benchtime 3m | |
time go test -v --bench BenchmarkIterateBolt --keys_mil 1 --valsz 64 --dir "/mnt/data/16kb" --timeout 60m |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment