1#!/bin/sh
2
3# Runs MeasureDiskOrderedScan -- see its source code for details.
4#
5# Meant to be run from the JEHOME directory.  Creates a JEHOME/tmp directory
6# to contain the data.  Must be run as root in order to execute the command to
7# clear the file system cache.
8#
9# This script populates the data and runs a single performance comparison.  It
10# is meant to be modified as needed.
11
12JEHOME="."
13CP="${JEHOME}/build/lib/je.jar:${JEHOME}/build/test/standalone/classes"
14ARGS="MeasureDiskOrderedScan -nRecords 5000000 -jeCacheSize 500000000"
15CMD="java -cp $CP -Xms1g -Xmx1g $ARGS"
16
17# Clear directory and Populate
18#rm -rf tmp && mkdir tmp
19#sync; echo 3 > /proc/sys/vm/drop_caches
20#$CMD -action Populate
21
22# DirtyReadScan
23#sync; echo 3 > /proc/sys/vm/drop_caches
24#$CMD -action DirtyReadScan
25
26# DiskOrderedScan
27sync; echo 3 > /proc/sys/vm/drop_caches
28$CMD -action DiskOrderedScan
29