Configuring pgbench-tools
The README
file that comes with pgbench-tools
is the definitive documentation about how to use the program. Current recommended practice, that the examples here will follow, is to create two databases for it to use. The primary one should be named pgbench
and it will contain the main database being tested. The second, named results
by default, will contain a summary of information about each test after it finishes.
Here is a sample session that creates both databases and initializes the results database:
$ cd pgbench-tools/ $ createdb pgbench $ createdb results $ psql -d results -f init/resultdb.sql
This may give you some error messages about tables it deletes not existing, these are normal—they are because DROP TABLE IF EXISTS
isn't available until PostgreSQL 8.2, and pgbench-tools
can in special cases be configured to run against 8.1 databases.
The results database doesn't even need to be on the same server as the one being tested. Making...