TiKV Server Startup Failure: Log Compacted

This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: TiKV server 启动失败 log compacted

| username: Timber

【TiDB Usage Environment】Production Environment
【TiDB Version】
【Reproduction Path】Power outage on-site, TiKV server failed to start, reporting an issue with missing SST files. After using ldb repair, the TiKV server was started. The TiKV server reported a duplicated store address error. Used ./pd-ctl store delete to remove the old store ID, but decommissioning failed. Then attempted to use ./pd-ctl unsafe remove-failed-store to delete the old store ID. At this point, TiKV could temporarily restart, but after running for a while, it reported a log compacted error and failed to restart.
【Encountered Problem: Symptoms and Impact】TiKV failed to start, how to fix the log compacted error
【Attachments: Screenshots/Logs/Monitoring】

| username: caiyfc | Original post link

I suggest you check if the disk is functioning properly; it is possible that a breakpoint has caused disk damage.

| username: redgame | Original post link

Under the condition that there are no hardware issues, use the command ./pd-ctl store remove <store_id> to remove the failed node from the PD cluster. After removing the failed node, restart the TiKV node and ensure the cluster rebalances.

| username: zhanggame1 | Original post link

You can use tiup for scaling up and down.

| username: 像风一样的男子 | Original post link

If there are enough nodes, delete this broken TiKV node.