Doris insert into 插入语句执行成功,且select查询成功,返回结果不报错,但查不到该插入数据

问题:Doris insert into 正常执行成功,select 查询也执行成功,但查不到该写入数据
原因:由于有其他 insert commit 事务待提交且该任务处于锁的状态,导致不断在回滚,进而造成其他的insert into 语句也执行成功,但是select不到写入的数据。一是集群性能太差的缘故,二是写入访问过多,导致查询tablet文件部分丢失,却回滚事务异常,Doris FE webui Log WARN日志打印初步判定是此原因,情况出现很少。


Doris FE 8030 WebUI WARN-Log 或者搜ERROR:

WARN (replayer|98) [BDBJournalCursor.next():148] Catch an exception when get next JournalEntity. key:12925859com.sleepycat.je.LockTimeoutException: (JE 18.3.12) Lock expired. Locker 1399794957 -1_replayer_ReplicaThreadLocker: waited for lock on database=12924945 LockAddr:1044707672 LSN=0x389/0xa5b46 type=READ grant=WAIT_NEW timeoutMillis=5000 startTime=1717660685364 endTime=1717660690364Owners: [


2024-06-06 16:09:17,902 WARN (mysql-nio-pool-13|355) [StmtExecutor.executeByLegacy():770] execute Exception. stmt[24765, 35fb3e655af74ffa-a62f0bbb830f6315]org.apache.doris.common.UserException: errCode = 2, detailMessage = (172.29.xxx.xx)[CANCELLED][INTERNAL_ERROR]failed to initialize storage reader. tablet=41483.2004477475.1d4d610d5642ea3b-9ac11667e188518b, res=[E-230]missed_versions is empty0. /root/src/doris-2.0/be/src/common/stack_trace.cpp:302: StackTrace::tryCapture() @ 0x000000000b86cf47 in /data/software/doris-1.2.4/be/lib/doris_be1. /root/src/doris-2.0/be/src/common/stack_trace.h:0: doris::get_stack_trace[abi:cxx11]() @ 0x000000000b86b5b5 in /data/software/doris-1.2.4/be/lib/doris_be2. /var/local/ldb-toolchain/bin/../lib/gcc/x86_64-linux-gnu/11/../../../../include/c++/11/bits/basic_string.h:187: doris::Status doris::Status::Error

解决:

-- 会话窗执行变量配置,关闭 insert 事务
set enable_odbc_transcation = false; 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

SunTecTec

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值