"ODBCBenchHOWTO" . "5c6538f9c617e788a4753602343d85e9" . . "ODBCBenchHOWTO" . "ODBCBenchHOWTO" . . . . . . . . . . . . . . "---+ ODBC Bench HOWTO\n\n%TOC%\n\n---++ Introduction\n\nThe following is a HOWTO document for using ODBC-Bench to benchmark your\nODBC data-sources. To send feedback / comments / suggestions, please email\nthe maintainer at iodbc@openlinksw.com.\n\nPrerequisites: basic Unix, Linux or MacOS X familiarity (creating\ndirectories and users, using an editor, etc).\n\n\n---++ Installing form pre-built binaries\n\nBinary distributions can be downloaded from [[http://oplweb.openlinksw.com/product/dldbench_cust.asp?dloadid=101646][OpenLink]] or the sourceforge.net [[http://sourceforge.net/project/showfiles.php?group_id=90508][project file-list page]] for a variety of OS/platforms.\n\n---++ Installing from Source\n\n\n---+++ Requirements\n\nTo build ODBC-Bench, you must have:\n\n * development tools: gcc (and dependencies), make etc; on MacOS X, this means having Xcode installed.\n * an ODBC driver manager such as [[http://www.iodbc.org/][iODBC]] or [[http://www.unixodbc.org/][unixODBC]] installed\n * libxml2 (greater than version 2.4.0), available from [[http://www.xmlsoft.org/][XMLsoft]] .\n\nMacOS X users please note: the version provided with MacOS X Jaguar is\nlibxml-2.2.x, which is not uptodate enough to build odbc-bench. You should\ninstall a newer version, either from xmlsoft or with\n[[http://fink.sourceforge.net/][Fink]] or\n[[http://darwinports.opendarwin.org/][Darwinports]] . Users of Panther and\nTiger already have sufficient versions with their OS as standard.\n\nOptionally, you can also build odbc-bench with support for a GUI, requiring\n\n * GTK, available from [[http://www.gtk.org/][GTK.org]] , complete with its requirements for the X window system etc.\n\nNote: on the Mac, use the version provided by\n[[http://fink.sourceforge.net/][Fink]] or\n[[http://darwinports.opendarwin.org/][Darwinports]] . There is also a\nproject to port GTK to Carbon directly, thereby obviating the need to use X\nwindows, at [[http://gtk-osx.sourceforge.net/][gtk-osx]] , but experiments\nshow it to be in need of greater development before odbc-bench will run\nwith it, so this is not currently recommended.\n\nThese can normally also be obtained from your unix vendor, or as packages\nor ports for GNU/Linux or FreeBSD distributions.\n\n\n---+++ Downloading\n\nYou can either download the latest tarball (odbc-bench-1.0.0.tar.gz) or check out the sources from CVS hosted on SourceForge.\n\nTo unpack the tarball, run\n\n\nbash$ zcat odbc-bench-0.99.21.tar.gz | tar xvf -\n\n\nor to check out sources from CVS, run\n\n\nbash$ cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/odbc-bench login\nbash$ cvs -qz3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/odbc-bench co odbc-bench\n\n\nIn the latter case, you also need to generate the configure script:\n\n\nbash$ sh bootstrap.sh\n\n\n---+++ Building\n\n\n---++++ Linux / Unix\n\nBuilding odbc-bench is simple. From the directory created in the above, run configure:\n\n\n\nbash$ ./configure --prefix=/usr/local/odbc-bench \\\n--with-iodbc=/usr/local/iODBC\n\n\nIn this case, we favour using /usr/local/odbc-bench/ to keep all the files\ntogether: you can omit the `--prefix' option and it will use /usr/local/ by\ndefault. If you only want the commandline version to be installed, now\nwould be the time to specify `--disable-gui' in the above command as well.\n\nNow run make, become root by your favoured method, and run make install:\n\n\nbash$ make\nbash$ su root -c 'make install'\n\n\n---++++ Mac OS X\n\nThe above configure and make method does not work with GTK on MacOS X, so we recommend you build a native Carbon app version instead:\n\n\n\nbash$ tar xvpfz odbc-bench-1.0.0.tar.gz\n...\nbash$ cd odbc-bench-1.0.0\nbash$ cd mac\nbash$ make \nbash$ make\nxcodebuild -buildstyle Deployment\n=== BUILDING NATIVE TARGET ODBC Bench USING BUILD STYLE Deployment ===\n\nPBXCp \"build/ODBC Bench.app/Contents/Info.plist\" \"build/odbc-bench.build/ODBC Bench.build/Info.plist\"\nmkdir -p \"/Volumes/Firewire/Users/tim/C/odbc-bench-1.0.0/mac/build/ODBC Bench.app/Contents\"\ncd /Volumes/Firewire/Users/tim/C/odbc-bench-1.0.0/mac\n/System/Library/PrivateFrameworks/DevToolsCore.framework/Resources/pbxcp -exclude .DS_Store -exclude CVS \n...\n * * BUILD SUCCEEDED **\nbash$ sudo make install\nPassword:\nsudo xcodebuild install -buildstyle Deployment install DSTROOT=/\n=== BUILDING NATIVE TARGET ODBC Bench USING BUILD STYLE Deployment ===\n\nPBXCp \"/Applications/ODBC Bench.app/Contents/Info.plist\" \"build/odbc-bench.build/ODBC Bench.build/Info.plist\" \n...\nSetMode a-w,a+rX \"/Applications/ODBC Bench.app\"\ncd /Volumes/Firewire/Users/tim/C/odbc-bench-1.0.0/mac\n/bin/chmod -RH a-w,a+rX \"/Applications/ODBC Bench.app\"\n * * BUILD SUCCEEDED **\n\n=== BUILDING NATIVE TARGET ODBC Bench USING BUILD STYLE Deployment ===\n * * BUILD SUCCEEDED ** \n\n\n---++ Running odbc-bench\n\nThis section guides you through setting ODBC-Bench to connect to a\ndatasource, configure a test and run it. You have the option of using the\nGTK or Carbon GUIs or running it all from the commandline.\n\n\n---+++Using the GUIs\n\nLinux / Unix uers can run `odbc-bench-gtk' from the commandline to bring up\nthe GUI; MacOS X users should open /Applications/ODBC Bench.app to start\nthe application:\n\n\"GUI\n\nThe idea of ODBC Bench is that you build pools of tests - you can configure\ncombinations of TPC-A or TPC-C tests with various parameters and save them\nout for later. By default, you have an untitled session into which you can\nadd tests to be run.\n\nFrom here, under the Edit menu, select `new benchmark item'. You can choose\na name for the test-run, and whether it's to use the TPC-A or TPC-C model:\n\n\"\"\n\nHaving chosen a name and model, under the Edit menu choose `Login Details',\nand specify a DSN, username and password to be used for the connection:\n\n\"\"\n\nNow select Edit / Table Details to set up the schema:\n\n\"\"\n\nHaving chosen which tables to use and how many rows with which to populate\nthem, proceed to connecting and creating them in the database with Action /\nCreate tables & Procedures:\n\n\"\"\n\nNext, configure the nature of the test to be run. You can specify all\ntransactions to take place on one or several threads, whether to use array\nparameters, whether to use direct execution of SQL queries, prepared\nstatements or stored procedures, whether to execute asynchronously, what\ntransaction-isolation level to use and what cursor model:\n\n\"\"\n\nFrom the Action menu, choose `Run Selected Tests', specify a duration and\noutput file, and press Start. If you defined a pool of multiple tests, you\ncan `Run All' instead:\n\n\"\"\n\nAs it progresses, you should see a completion-indicator for each thread:\n\n\"\"\n\nFinally, the results are displayed:\n\n\"\" \n\nYou can build a list of tests - DSNs and test configurations - against\nwhich to run odbc-bench, and then select them for running in bulk.\n\n\n---+++ Using the CLI\n\nThe command-line interface to odbc-bench is invoked with the odbc-bench-cmd command. As an overview of the options it takes, this is the `--help' output:\n\n\n\nbash$ odbc-bench-cmd --help\n\nOpenLink ODBC Benchmark Utility 0.99.22\nCopyright (C) 2000-2003 OpenLink Software\nPlease report all bugs to <odbc-bench@openlinksw.com>\n\nThis utility is released under the GNU General Public License (GPL)\n\nDisclaimer: The benchmarks in this application are loosely based\non the TPC-A and TPC-C standard benchmarks, but this application\ndoes not claim to be a full or precise implementation, nor are\nthe results obtained by this application necessarily comparable\nto the vendor's published results.\n\nUsage :\n\n-d -dsn - login dsn\n-u -uid - user id\n-p -pwd - password\n-r -runs - number of runs (default 1)\n-m -time - duration of the run (mins) (default 1)\n-t -threads - number of threads (default 1)\n-P -arrayparm - size for used array of parameters (default 1) \n-s -test - exec | proc | prepare | runall (default 'exec' test)\n-x -txn - use transactions (default 'don't use transactions')\n-1 -query - do 100 row query\n-a -async - asynchronous execution\n-c -cursor_type - cursor type = forward | static | keyset | dynamic | \nmixed (default 'forward')\n-i -txn_isolation - transaction isolation level = uncommitted | committed \n| repeatable | serializable\n(default 'Driver Default')\n-S -rowset_size - rowset size (default 1)\n-K -keyset_size - keyset size (default 1)\n-T -trav_count - traversal count (default 1)\n-C -create_tables - create the tables and procedures, then exit\n-D -drop_tables - drop the tables and procedures, then exit\n-rcreate_table - create the results table, then exit\n-rdrop_table - drop the results table, then exit\n-rdsn - login dsn for result table\n-ruid - user id for result table\n-rpwd - password for result table\n-rfile - output filename for results data\n-v - print info on stdout (error messages, test results,\nmessages about the creation and closing connections)\n-V - print the same info on stdout as for -v and the test progress info\n-R - doesn't do rollbacks on deadlock\n\n\nA reasonable way to run it is as follows - corresponding to the above settings:\n\n\n\nbash$ odbc-bench-cmd -d \"pglocal\" -u tim -p \"\" -D\nbash$ odbc-bench-cmd -d \"pglocal\" -u tim -p \"\" -C\nbash$ odbc-bench-cmd -d \"pglocal\" -u tim -p \"\" -r 1 -t 4 -s prepare \\\n-c keyset -S 5 -K 5 -v |& tee run.log\n\n\nThe first of these lines drops any pre-existing tables in the database. The\nsecond re-creates them, and the third performs the run with semi-verbose\noutput tee'd into a logfile.\n\nThe output looks like:\n\n\n\nConnecting to CommandLine : DSN=<pglocal> UID=<tim>\nDriver : 07.02.0005 (libpsqlodbc.so)\nConnection to CommandLine opened\n\nConnection to CommandLine closed\n\nConnecting to CommandLine : DSN=<pglocal> UID=<tim>\nDriver : 07.02.0005 (libpsqlodbc.so)\nConnection to CommandLine opened\n\nCommandLine - PostgreSQL(libpsqlodbc.so) - all 4 TPC-A Threads completed\nsuccessfully.\nCalculating statistics:\nSQL options used: 4 Threads/Params\nTransaction time: 61.000000\nEnvironmental overhead: -1.000000\nTotal transactions: 7835\nTransactions per second: 128.442627\n% less than 1 second: 100.000000\n% 1 < n < 2 seconds: 0.000000\nAverage processing time: 0.007786\nConnection to CommandLine closed\n\n\n---++ References\n\n * Overview of the [[http://www.tpc.org/tpca/default.asp][TPC-A]] benchmark specification\n * Overview of the [[http://www.tpc.org/tpcc/default.asp][TPC-C]] benchmark specification\n * The [[http://www.iodbc.org/][iODBC]] driver manager homepage\n * The [[http://www.unixodbc.org/][unixODBC]] driver manager homepage\n * [[http://www.openlinksw.com/][OpenLink Software]] (ODBC drivers, et al)\n * [[http://www.microsoft.com/data/odbc/][Microsoft ODBC]] site\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" . . . . . "2016-09-14T12:28:33Z" . . "2016-09-14T12:28:33Z" . . . . . . . . . . . "2016-09-14T12:28:33.536395"^^ . . . . "2016-09-14T12:28:33.536395"^^ . . . . .