From: Michael Vrable Date: Mon, 14 Feb 2011 05:57:38 +0000 (-0800) Subject: Add a "native" target to run the kernel NFS server. X-Git-Url: http://git.vrable.net/?p=bluesky.git;a=commitdiff_plain;h=536dd54d55f99936ffcdb3eaa39d44f5ec3114a3 Add a "native" target to run the kernel NFS server. --- diff --git a/microbench/run2.sh b/microbench/run2.sh index 04f685b..fbfbc25 100755 --- a/microbench/run2.sh +++ b/microbench/run2.sh @@ -34,8 +34,8 @@ BENCH_DIRSIZE=128 #for size in 128 256 512 768 1024 1536 2048; do # for filesize in 4 32 256 2048; do -for size in 128 512 2048; do - for filesize in 4 1024; do +for size in 128 512 1024 2048; do + for filesize in 1024; do BENCH_FILESIZE=$(($filesize * 1024)) BENCH_FILECOUNT=$(($size * 1024 / $filesize / $BENCH_THREADS)) PREFIX=$BLUESKY_TARGET-$BENCH_WRITERATIO-${size}M-${filesize}k diff --git a/microbench/setup/cleanup-proxy b/microbench/setup/cleanup-proxy index 80fd963..e88e7fe 100755 --- a/microbench/setup/cleanup-proxy +++ b/microbench/setup/cleanup-proxy @@ -4,5 +4,22 @@ . /scratch/aws-keys -rm -rf /export/journal -/scratch/bluesky.git/microbench/setup/s3-cleanup.py +export BLUESKY_TARGET=s3 +# Export any environment variables specified on the command line +for e in "$@"; do + echo "$e" 1>&2 + if echo "$e" | grep = >/dev/null; then + eval "$e" + export ${e%=*} + fi +done + +if [ "$BLUESKY_TARGET" = "native" ]; then + /etc/init.d/nfs-kernel-server stop + umount /export + mkfs.ext3 /dev/sda10 + mount /export +else + rm -rf /export/journal + /scratch/bluesky.git/microbench/setup/s3-cleanup.py +fi diff --git a/microbench/setup/run-proxy b/microbench/setup/run-proxy index 928fcee..80ec5be 100755 --- a/microbench/setup/run-proxy +++ b/microbench/setup/run-proxy @@ -16,5 +16,9 @@ for e in "$@"; do fi done -mkdir /export/journal 2>/dev/null -(cd /export; /scratch/bluesky.git/nfs3/nfsproxy) +if [ "$BLUESKY_TARGET" = "native" ]; then + /etc/init.d/nfs-kernel-server start +else + mkdir /export/journal 2>/dev/null + (cd /export; /scratch/bluesky.git/nfs3/nfsproxy) +fi diff --git a/microbench/setup/stop-proxy b/microbench/setup/stop-proxy index 4d506f8..482a7e4 100755 --- a/microbench/setup/stop-proxy +++ b/microbench/setup/stop-proxy @@ -1,3 +1,17 @@ #!/bin/bash -pkill -INT nfsproxy +export BLUESKY_TARGET=s3 +# Export any environment variables specified on the command line +for e in "$@"; do + echo "$e" 1>&2 + if echo "$e" | grep = >/dev/null; then + eval "$e" + export ${e%=*} + fi +done + +if [ "$BLUESKY_TARGET" = "native" ]; then + /etc/init.d/nfs-kernel-server stop +else + pkill -INT nfsproxy +fi