1. 使用测试-当前环境
[gbasedbt@node01 ~]$ cat profile.node1
export GBASEDBTSERVER=node1
export GBASEDBTDIR=/home/gbasedbt/gbase
export GBASEDBTSQLHOSTS=/home/gbasedbt/gbase/etc/sqlhosts.node1
export ONCONFIG=onconfig.node1
export PATH=/home/gbasedbt/gbase/bin:$PATH
export DB_LOCALE=zh_CN.utf8
export CLIENT_LOCALE=zh_CN.utf8
export GL_USEGLU=1
export GL_DATE="%Y-%m-%d"
export GL_DATETIME="%Y-%m-%d %H:%M:%S"
export PSORT_NPROCS=4
export PDQPRIORITY=100
alias dbaccess="rlwrap dbaccess"
export DBACCESS_SHOW_TIME=1
[gbasedbt@node01 ~]$ onstat -g cfg|grep ^DS_
Your evaluation license will expire on 2025-06-26 00:00:00
DS_HASHSIZE 31
DS_POOLSIZE 127
DS_MAX_QUERIES 4
DS_TOTAL_MEMORY 4096000
DS_MAX_SCANS 1048576
DS_NONPDQ_QUERY_MEM 20480
> select count(*) from test;
(count(*))
5594846
2. PDQ测试-并检查
[gbasedbt@node01 ~]$ dbaccess test -
Your evaluation license will expire on 2025-06-26 00:00:00
Database selected.
> set PDQPRIORITY 60;
PDQ Priority set.
Elapsed time: 0.001 sec
> select id,count(*) from test group by id;
id (count(*))
50672 56
85521 47
15588 48
63243 60
59116 48
53026 46
63799 65
39676 66
50928 52
10717 74
59986 54
28078 62
95875 56
74312 70
79294 62
72278 65
91819 54
1899 51
45370 57
68540 61
13790 62
[gbasedbt@node01 ~]$ onstat -g mgm
Your evaluation license will expire on 2025-06-26 00:00:00
On-Line -- Up 01:33:16 -- 3228180 Kbytes
Memory Grant Manager (MGM)
--------------------------
MAX_PDQPRIORITY: 100
DS_MAX_QUERIES: 4
DS_MAX_SCANS: 1048576
DS_NONPDQ_QUERY_MEM: 20480 KB
DS_TOTAL_MEMORY: 4096000 KB
Queries: Active Ready Maximum
1 0 4
Memory: Total Free Quantum
(KB) 4096000 1638400 1024000
Scans: Total Free Quantum
1048576 1048572 1
Load Control: (Memory) (Scans) (Priority) (Max Queries) (Reinit)
Gate 1 Gate 2 Gate 3 Gate 4 Gate 5
(Queue Length) 0 0 0 0 0
Active Queries:
---------------
Session Query Priority Thread Memory Scans Gate
--有使用PDQ并行查询的sql
34 51a10038 60 505cb4c0 0/307200 0/4 -
Ready Queries: None
Free Resource Average # Minimum #
-------------- --------------- ---------
Memory 4.7 +- 28.9 0
Scans 1048576.0 +- 0.0 1048572
Queries Average # Maximum # Total #
-------------- --------------- --------- -------
Active 1.0 +- 0.0 1 2000022
Ready 1.0 +- 0.0 1 290644
Resource/Lock Cycle Prevention count: 0