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 the tables that it deletes not existing; these are normal, they are because ...

Get PostgreSQL 10 High Performance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.