---
title: OceanBase 创建索引 hang，系统报错 -4023-OceanBase数据库使用指南
description: 了解OceanBase数据库在实际应用中关于OceanBase 创建索引 hang，系统报错 -4023相关的常见问题和使用技巧，帮助您快速解决OceanBase 创建索引 hang，系统报错 -4023的难题。
---
切换语言

- 中文站 - 简体中文
- International - English
- 日本站 - 日本語

划线反馈

# OceanBase 创建索引 hang，系统报错 -4023

更新时间：2026-05-22 08:56

适用版本： V2.2.x、V3.1.x、V3.2.x 内容类型：Troubleshoot  

## 问题描述

OceanBase 数据库创建索引卡住，从 `__all_rootservice_event_history` 中和 `observer.log` 中均看到 -4023 报错，日志内容如下。

```shell
WARN [CLOG] get_last_archived_log_info (ob_partition_log_service.cpp:3803) [114995][1454][xxxxx-xxxxx] [lt=18] [dc=0] incarnation or archive round is not the same, need retry(ret=-4023, partition_key={tid:xxxxx, partition_id:22, part_cnt:0}, incarnation=1, archive_round=1, log_archive_status_={status:0, start_ts:-1, archive_incarnation:0, log_archive_round:0, last_archived_log_id:xxxxxx, last_archived_log_ts:-1, clog_epoch_id:-1, accum_checksum:0})
WARN [STORAGE] get_curr_clog_info_ (ob_partition_group.cpp:3817) [114995][1454][xxxxx-xxxxx] [lt=11] [dc=0] failed to get_last_archived_log_info(ret=-4023, ret="OB_EAGAIN", pkey_={tid:xxxxx, partition_id:22, part_cnt:0}, info={status:{tenant_id:1, start_ts:xxxxx, checkpoint_ts:0, status:2, incarnation:1, round:1, status_str:"BEGINNING"}, backup_dest:"file:///data/1/backup"})
WARN [STORAGE] get_curr_storage_info (ob_partition_group.cpp:3868) [114995][1454][xxxxx-xxxxx] [lt=11] [dc=0] fail to get curr clog info(ret=-4023, pkey_={tid:xxxxx, partition_id:22, part_cnt:0})

```

## 适用版本

OceanBase 数据库 V2.x 和 V3.x 版本。

## 问题原因

归档缓慢或者卡主，导致索引创建无法继续。

- 创建索引过程中需要复制 SSTable（类似于副本的迁移操作），为了避免复制过程中发生切主可能导致的归档日志的不连续，要求复制 SSTable 时 leader 的归档日志点位要大于副本的点位。
 - 如果归档缓慢，或者备份盘满而不能归档，则索引创建会被卡住。

## 解决方法

需要解决日志备份延迟的问题，才能解决创建索引卡住的问题。

上一篇

[__all_virtual_partition_info 不包含本地索引的信息](https://www.oceanbase.com/knowledge-base/oceanbase-database-1000000000450145)

下一篇

[如何查询全局索引的创建进度](https://www.oceanbase.com/knowledge-base/oceanbase-database-1000000000243972) ![有帮助](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*y6ocSqN8cqsAAAAAAAAAAAAAARQnAQ)![无帮助](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*BG9IQJyLHF8AAAAAAAAAAAAAARQnAQ)![反馈](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*eTWdQKCRKHwAAAAAAAAAAAAAARQnAQ)[AI](https://www.oceanbase.com/obi) 咨询热线
