tidb版本 6.1.7
tiflash配置如下:
tiflash:
log.file.max-days: 30
profiles.default.max_memory_usage: 4294967296
profiles.default.max_memory_usage_for_all_queries: 8589934592
mpp配置默认。
mysql> show variables like '%mpp%';
+------------------------------------------+-------+
| Variable_name | Value |
+------------------------------------------+-------+
| tidb_allow_mpp | ON |
| tidb_enforce_mpp | OFF |
| tidb_mpp_store_fail_ttl | 60s |
| tidb_opt_mpp_outer_join_fixed_build_side | OFF |
+------------------------------------------+-------+
4 rows in set (0.00 sec)
mysql>
现在连接tidb节点查数具体操作如下
ERROR 1105 (HY000): other error for mpp stream: DB::Exception: Memory limit (for query) exceeded: would use 4.00 GiB (attempt to allocate chunk of 10512061 bytes), maximum: 4.00 GiB: (while reading from DTFile: /work/tidb-oltp-145-v6.1.7/data/tiflash-34145/data/t_77/stable/dmf_1252)
可以发现执行一条简单的select limit 1会报内存不够,这算是bug还是预期内的现象呢。