关于并行查询调优涉及的相关知识[收集中]

本文探讨了数据库中并行查询的工作原理,包括一致性直接读取机制、协调者进程的作用及并行处理时间的计算。此外,还介绍了如何通过V$PQ_TQSTAT视图分析并行查询中的数据分布不均问题。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

1、

并行查询、直接加载(direct load)大表等时,会发生一致性直接读取(consistent gets direct),即服务器进程会绕过高速缓存(buffer cache)直接从磁盘上的数据文件读取数据块,发送给客户端的用户进程。

2、V$PQ_TQSTAT

V$PQ_TQSTAT has a row for each query server process that it reads from or writes to in each table queue. A table queue connecting 10 consumer processes to 10 producer processes has 20 rows in the view.Total the bytes column and group by TQ_ID, and the table queue identifier, to obtain the total number of bytes sent through each table queue. Compare this to the optimizer estimates; large variations might indicate a need toanalyze the data using a larger sample.

Compute the variance of bytes grouped by TQ_ID. Large variances indicateworkload imbalances. You should investigate large variances to determine whether the producers start out with unequal distributions of data, or whether the distribution itself is skewed. If the data itself is skewed, this might indicate a low cardinality, or low number of distinct values.


参考:http://docs.oracle.com/cd/E11882_01/server.112/e25523/parallel006.htm


3、协调者进程是要等所有的并行服务器进程执行完毕将结果集都已经传送到协调者进程这里后才会将整合的结果集发送给客户端进程的。


4、并行处理的时间=从属【并行】并行服务器进程中最慢的那个所用的处理以及传送数据给协调者进程的时间+协调者进程汇总整合结果的时间


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值