【 TiDB 使用环境】生产环境 or 测试环境 or POC
【 TiDB 版本】
v4.0.8
【遇到的问题】
执行某些聚合查询的SQL,会出现region is unavaileable
看了SQL的执行计划,都是sum group by,并且自动分配到tiflash上执行
【复现路径】做过哪些操作出现的问题
【问题现象及影响】
执行某个聚合计算的SQL,主要是sum group by,数据量大约300w,报region is availavle
同时tiflash的错误日志中,有以下的报错信息
2.09.11 22:08:38.041389 [ 329026351 ] CoprocessorHandler: grpc::Status DB::CoprocessorHandler::execute(): RegionException: region 1683245, message: NOT_FOUND: (while creating InputStreams from storage db_48
.t_1858
, table_id: 1858)
2022.09.11 22:08:42.969253 [ 329021362 ] DAGQueryBlockInterpreter: Check after read from Storage, region 1683240, version 1560, handle range [2799039587, 2799056972), status VERSION_ERROR
2022.09.11 22:08:42.974485 [ 329021362 ] DAGQueryBlockInterpreter: RegionException after read from storage, regions [1683240,], message: VERSION_ERROR, retry to read from local
2022.09.11 22:08:43.182245 [ 329021421 ] DAGQueryBlockInterpreter: Check after read from Storage, region 1683240, version 1560, handle range [2799039587, 2799056972), status VERSION_ERROR
2022.09.11 22:08:43.206093 [ 329021421 ] DAGQueryBlockInterpreter: RegionException after read from storage, regions [1683240,], message: VERSION_ERROR, retry to read from local
2022.09.11 22:08:46.022185 [ 329033088 ] DAGQueryBlockInterpreter: Check after read from Storage, region 1683240, version 1560, handle range [2799039587, 2799056972), status VERSION_ERROR
2022.09.11 22:08:46.022305 [ 329021933 ] DAGQueryBlockInterpreter: Check after read from Storage, region 1683240, version 1560, handle range [2799039587, 2799056972), status VERSION_ERROR
2022.09.11 22:08:46.040664 [ 329033088 ] DAGQueryBlockInterpreter: RegionException after read from storage, regions [1683240,], message: VERSION_ERROR, retry to read from local
2022.09.11 22:08:46.053768 [ 329021933 ] DAGQueryBlockInterpreter: RegionException after read from storage, regions [1683240,], message: VERSION_ERROR, retry to read from local
2022.09.11 22:09:02.994684 [ 329037158 ] pingcap.tikv: Failed4: Deadline Exceeded
2022.09.11 22:09:03.233701 [ 329037232 ] pingcap.tikv: Failed4: Deadline Exceeded
【附件】 相关日志及监控(https://metricstool.pingcap.com/)
若提问为性能优化、故障排查类问题,请下载脚本运行。终端输出的打印结果,请务必全选并复制粘贴上传。