mysql benchmark 安装_benchmark在postgresql上的安装及使用

1.创建用户和数据库

[postgres#localhost ~] $ psql postgres

psql (9.5.2)

Type "help" for help.

postgres=# CREATE USER benchmarksql WITH ENCRYPTED PASSWORD 'changeme';

postgres=# CREATE DATABASE benchmarksql OWNER benchmarksql;

postgres=# \q

2.解压

[postgres@localhost run]$unzip benchmarksql-5.0.zip

[postgres@localhost ~] $ cd benchmarksql-5.0

[postgres@localhost benchmarksql-5.0]$ ant

bash: ant: command not found...

解决方法:

安装ant

[root@localhost etc]# yum install ant

[postgres@localhost benchmarksql-5.0]$ ant

Buildfile: /tmp/benchmarksql-5.0/build.xml

init:

[mkdir] Created dir: /tmp/benchmarksql-5.0/build

compile:

[javac] Compiling 11 source files to /tmp/benchmarksql-5.0/build

dist:

[mkdir] Created dir: /tmp/benchmarksql-5.0/dist

[jar] Building jar: /tmp/benchmarksql-5.0/dist/BenchmarkSQL-5.0.jar

BUILD SUCCESSFUL

Total time: 2 seconds

3.修改文件

[postgres@localhost benchmarksql] $ cd run

[postgres@localhost run] $ cp props.pg my_postgres.properties

[postgres@localhost run] $ vi my_postgres.properties

[postgres@localhost run] $

4.构建模式和初始数据库加载

[postgres@localhost run]$ ./runDatabaseBuild.sh my_postgres.properties

# ------------------------------------------------------------

# Loading SQL file ./sql.common/tableCreates.sql

# ------------------------------------------------------------

create table bmsql_config (

cfg_name varchar(30) primary key,

cfg_value varchar(50)

);

Starting BenchmarkSQL LoadData

driver=org.postgresql.jdbc.Driver

conn=jdbc:postgresql://localhost:5866/benchmarksql

user=benchmarksql

password=***********

warehouses=1

loadWorkers=4

fileLocation (not defined)

csvNullValue (not defined - using default 'NULL')

Worker 000: Loading ITEM

Worker 001: Loading Warehouse 1

Worker 000: Loading ITEM done

Worker 001: Loading Warehouse 1 done

# ------------------------------------------------------------

# Loading SQL file ./sql.common/indexCreates.sql

# ------------------------------------------------------------

# ------------------------------------------------------------

# Loading SQL file ./sql.postgres/extraHistID.sql

# ------------------------------------------------

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值