Skip to content

ClickHouse never remove part_moves_shard task node when using 'move parition to shard'. #40814

@zhaojintaozhao

Description

@zhaojintaozhao

ClickHouse never remove part_moves_shard task node when using 'move parition to shard'.

Hi all.
In my system, there are two shards and two replicas,I use 'move partition to shard' to move part between shards. I find that after part moving task, ClickHouse never remove part_moves_shard task node in zookeeper.

The procedure is as follows:
1st, create a ReplicatedMergeTree table on cluster.
2nd, import data to the shard1 replica1 node.
3rd, move partition to shard2 in shard1replica1. #17871
4th. after task finished, check task node under part_moves_shard, thease task node like 'task-0000000000' never remove.

How to reproduce:

In shard1 replica1:
1st: create table test on cluster '{cluster}' (key UInt32, value1 String, value2 String, value3 String) engine=ReplicatedMergeTree('/clickhouse/{shard}/test', '{replica}') order by key partition by (key % 4)

2nd: insert into test select * from generateRandom('key UInt32, value1 String, value2 String, value3 String') limit 1000000

3rd: alter table test move part '0_0_0_0' to shard '/clickhouse/02/test';

In shard2 replica1:
4th: select * from test limit 2, we can query data from shard2replica1;

5th: check part move task node under '/clickhouse/01/test/part_moves_shard'

We can find part move task like '/clickhouse/01/test/part_moves_shard/task-0000000000'. Though task state of 'task-0000000000' is 'done', but this node will never to be removed.

Do other friends have similar problems?

Metadata

Metadata

Assignees

No one assigned

    Labels

    experimental featureBug in the feature that should not be used in productionnot plannedKnown issue, no plans to fix it currenlty

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions