[tahoe-dev] Benchmarking script

Kyle Markley kyle at arbyte.us
Sun Aug 15 04:46:42 UTC 2010


Developers,

Attached is my initial version of a tahoe benchmarking script.  I'm making
it available now, but I don't consider it done, because I'm still having
some trouble with it on Windows.  It's Perl; sorry about that, but I don't
know Python.

Description:

The script's purpose is to create an environment for reproducible
benchmarking.  It creates a temporary tahoe grid across several machines,
initially empty, and one machine then runs a sequence of commands (from a
text file) whose output and runtime are logged.  When all the commands have
finished, the temporary grid is destroyed.

Arguments:

  -tahoe STRING
The given STRING is used to invoke tahoe on this system.  Point it to your
specially-built version of tahoe, or, on Windows, use something like
-tahoe="\Python26\python.exe \Python26\Scripts\tahoe-script.py".  Defaults
to "tahoe".

  -log FILE
Logfile that will be appended to with the benchmarking results.  Defaults
to "tahoe-bench.log".


  -storage_port NNNN
Run as a storage node.  Create a socket, listening on port NNNN for
connections from the client benchmarking script.  All the machines acting
as storage nodes should be started before the benchmarking client script is
started.


  -storage_nodes FILE
A text file, one entry per line, providing the address:port of the
benchmarking script(s) acting as storage nodes.

  -config FILE
A template tahoe.cfg file.  It will be used as-is by the benchmarking
client node, but with its nickname and introducer.furl automatically
overridden.

  -commands FILE
A text file, one entry per line, of commands to execute after the
temporary grid is created.  The output and timing of these commands will be
written to a logfile.  Three special strings will be automatically
replaced:
  TAHOE will be replaced with the tahoe invocation as given by the -tahoe
argument
  NODE will be replaced with the node directory (commands should always
use -d NODE)
  ROOT will be replaced with the name of a default rootcap

All three of -storage_nodes, -config, and -commands must be given in order
to run as a benchmarking client.

Example -storage_nodes file:
192.168.1.10:5000
localhost:3000

Example -commands file:
TAHOE backup -d NODE /tmp/smallfiles ROOT:smallfiles
TAHOE backup -d NODE /tmp/largefiles ROOT:largefiles


Also attached is a script I've used to create random files for tahoe
benchmarking commands to work with.


(P.S., The trouble I'm having on Windows is due to the fact that "tahoe
start" doesn't completely daemonize there; it doesn't return me to my
command shell immediately.  And curiously, even if I kill the python
processes from the task manager, sometimes the WAPI still responds.  I'd
like to understand more about how tahoe starts on Windows and how to
completely kill it, especially if its node directory has already been
deleted.)

-- 
Kyle Markley
-------------- next part --------------
A non-text attachment was scrubbed...
Name: generate_data.sh
Type: application/octet-stream
Size: 265 bytes
Desc: not available
URL: <http://tahoe-lafs.org/pipermail/tahoe-dev/attachments/20100815/add9b16d/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tahoe-bench.pl
Type: application/octet-stream
Size: 10993 bytes
Desc: not available
URL: <http://tahoe-lafs.org/pipermail/tahoe-dev/attachments/20100815/add9b16d/attachment-0001.obj>


More information about the tahoe-dev mailing list