GBase 8a
性能调优
问答

GBase 8a使用benchmarksql测试的教程

发表于2025-11-12 11:12:0792次浏览5个评论

为提高效率,提问时请提供以下信息,问题描述清晰可优先响应。

【GBase版本】:GBase8a_MPP_Cluster-NoLicense-FREE-9.5.3.28.12-redhat8-aarch64

【操作系统】:Kylin Linux Advanced Server V10 (Halberd)

【CPU】:飞腾S5000C-E

【问题描述】*:麻烦提供一下GBase 8a使用benchmarksql测试的教程

配置如下:

[root@client3 run]# cat props.gbase
db=gbase
driver=com.gbase.jdbc.Driver
conn=jdbc:gbase://11.1.1.2:5050/testdb
user=test
password=Phytium123123

warehouses=100
loadWorkers=20

terminals=100
//To run specified transactions per terminal- runMins must equal zero
runTxnsPerTerminal=0
//To run for specified minutes- runTxnsPerTerminal must equal zero
runMins=10
//Number of total transactions per minute
limitTxnsPerMin=1000000000

//Set to true to run in 4.x compatible mode. Set to false to use the
//entire configured database evenly.
terminalWarehouseFixed=true

//The following five values must add up to 100
//The default percentages of 45, 43, 4, 4 & 4 match the TPC-C spec
newOrderWeight=45
paymentWeight=43
orderStatusWeight=4
deliveryWeight=4
stockLevelWeight=4

// Directory name to create for collecting detailed result data.
// Comment this out to suppress.
//resultDirectory=my_result_%tY-%tm-%td_%tH%tM%tS
//osCollectorScript=./misc/os_collector_linux.py
//osCollectorInterval=1
//osCollectorSSHAddr=user@dbhost
造数却报错:

[root@client3 run]# ./runDatabaseBuild.sh props.gbase
# ------------------------------------------------------------
# Loading SQL file ./sql.common/tableCreates.sql
# ------------------------------------------------------------
Access denied for user 'test'@'%' to database 'testdb'
Starting BenchmarkSQL LoadData

driver=com.gbase.jdbc.Driver
conn=jdbc:gbase://11.1.1.2:5050/testdb
user=test
password=***********
warehouses=100
loadWorkers=20
fileLocation (not defined)
csvNullValue (not defined - using default 'NULL')

ERROR: Access denied for user 'test'@'%' to database 'testdb'
# ------------------------------------------------------------
# Loading SQL file ./sql.common/indexCreates.sql
# ------------------------------------------------------------
Access denied for user 'test'@'%' to database 'testdb'
# ------------------------------------------------------------
# Loading SQL file ./sql.common/foreignKeys.sql
# ------------------------------------------------------------
Access denied for user 'test'@'%' to database 'testdb'
ERROR: Cannot locate SQL file for extraHistID
# ------------------------------------------------------------
# Loading SQL file ./sql.common/buildFinish.sql
# ------------------------------------------------------------
Access denied for user 'test'@'%' to database 'testdb'
 

评论

登录后才可以发表评论
pikaysw发表于 8个月前
报错Access denied for user 'test'@'%' to database 'testdb'是因为没有对test用户赋予testdb的权限
发表于 8个月前
@pikaysw:gbase> SHOW GRANTS FOR 'test'@'%';
+-------------------------------------------------------------------------------------------------------------------------------------+
| Grants for test@% |
+-------------------------------------------------------------------------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.*.* TO 'test'@'%' IDENTIFIED BY PASSWORD '*7801FD2CD9C1BD4202B5D929B50908F5BC9653B1' WITH TASK_PRIORITY 2 |
| GRANT ALL PRIVILEGES ON "vc00002"."testdb".* TO 'test'@'%' |
+-------------------------------------------------------------------------------------------------------------------------------------+
2 rows in set (Elapsed: 00:00:00.00)
赋予了权限
pikaysw发表于 8个月前
@F²:在客户端里直接执行tableCreates.sql里的内容会报错么。
或者直接在配置文件中使用管理员用户gbase连接数据库试试
用户头像
GBase用户28017发表于 8个月前
厉害。
枫溪发表于 8个月前
666