返回首页

gbase数据、南大通用产品文档:GBase8sonmode W: 更改 SQL 语句高速缓存的设置

更新日期:2024年09月11日

语法:

元素
用途
关键注意事项
STMT_CACHE_HITS hits
指定语句完全插入到
SQL 语句高速缓存之
前,对它的命中(引
用)数。将 hits 设
置为 1 或更大可防
止特定查询进入高速
缓存
仅可增加或重设STMT_CACHE_HITS
的值。新值显示在 onstat -g ssc
输出的 #hits 字段中。
如果 hits
=
0 ,数据库服务器在高速缓存中
插入所有符合条件的语句及其内
存结构。如果 hits > 0 并且 SQL
语句的已执行次数小于
STMT_CACHE_HITS ,
那么数据库服
务器会在高速缓存插入 key-only
条目。
在已将语句执行了指定命中
次数之后,
它在高速缓存中插入符
合条件的语句。ONCONFIG 参数:
STMT_CACHE_HITS
STMT_CACHE_NOLIMIT value
控制语句是否插入
SQL 语句高速缓存
如果 value = 0,那么数据库服务
器在高速缓存中插入语句。如果
value = 1,数据库服务器总是在
高速缓存中插入语句。
如果没有共
享任何查询,那么关闭

GBase 8s 管理员参考
南大通用数据技术股份有限公司 - 376 -
元素
用途
关键注意事项
STMT_CACHE_NOLIMIT 可防止数据
库服务器为高速缓存分配大量内
存。ONCONFIG 参数:
STMT_CACHE_NOLIMIT

SQL 语句高速缓存示例
以下是用于更改 SQL 语句高速缓存(SSC)设置的 onmode -W 命令的示例。更改只对当
前数据库会话生效,且不能更改 ONCONFIG 值。重新启动数据库服务器时,它使用缺省
的 SSC 设置(如果未在 ONCONFIG 文件中指定)或 ONCONFIG 设置。要做出永久更
改,请设置相应的配置参数。
onmode -W STMT_CACHE_HITS 2 # number of hits before statement is
# inserted into SSC
onmode -W STMT_CACHE_NOLIMIT 1 # always insert statements into
# the cache
该命令有等同的 SQL 管理 API 函数。

High Performance
The single-node data computing engine automatically selects the optimal execution
plan and algorithm through rule-based and cost-based cost evaluation. Leveraging
columnar storage, efficient compression, and intelligent indexing technologies, it
saves three orders of magnitude in CPU and I/O resource consumption, and achieves
query performance 50 to 1000 times higher than traditional row-based databases.
It supports deploying multiple computing nodes on multi-NUMA node servers,
binding each computing node to a NUMA node to avoid performance degradation
caused by cross-NUMA node operations. Multi-instance deployment can improve
performance by more than 1x.
Massive Parallel Processing (MPP) Technology
GBase 8a MPP Cluster is an asymmetrically deployed federated architecture, where
the three core components can be deployed separately. The maximum number of
nodes supported for GCluster scheduling cluster and GCWare management is 64,
and the GNode computing cluster supports deployment of more than 1000 nodes,
capable of handling structured data of over 100 PB.

GBase 8a MPP Cluster Technical White Paper
- 14 -
General Data Technology Co., Ltd.

会话状态
通过本功能您可以查看会话状态信息,如下图所示:

GBaseDataStudio 管理工具手册
- 234 -
南大通用数据技术股份有限公司
图5- 611 会话状态