Skip to content

HDDS-13054. [DiskBalancer] Stop DiskBalancer when DN enters DECOMMISSIONING or MAINTENANCE states #8488

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: HDDS-5713
Choose a base branch
from

Conversation

Gargi-jais11
Copy link
Contributor

@Gargi-jais11 Gargi-jais11 commented May 20, 2025

What changes were proposed in this pull request?

When DN enters in DECOMMISSIONING or MAINTENANCE states, DiskBalancer on that DN should be stopped and resume again after DN turns to normal state. This needs to be fixed.

This JIRA also tracks the addition of integration tests to validate DiskBalancer's behaviour when a DataNode (DN) transitions into DECOMMISSIONING or MAINTENANCE states.

Test Scenarios: When DiskBalancer is running mark one DN as Decommissioned and other as Maintenance.

Setup: Create a cluster with 5 DNs, each having multiple data volumes.

Description: Start DiskBalancer on all DNs. While it's actively balancing, decommission one of the DNs and mark other DN state as Maintenance.
Expected Behaviour:

Disk balancer should pause itself if the DN state is maintenance or decomissioning, decomissioned.
DN status marked as STOPPED and should not include the decommissioned DataNode in the output of diskbalancer status and report.
Other active DataNodes should continue balancing without disruption.

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-13054

How was this patch tested?

Added Integration Test TestDiskBalancerDuringDecommissionAndMaintenance

@Gargi-jais11 Gargi-jais11 changed the title HDDS-13054. [DiskBalancer] Add Integration Test for DiskBalancer with Decommissioning and Maintenance DNs HDDS-13054. [DiskBalancer] Stop DiskBalancer when DN enters DECOMMISSIONING or MAINTENANCE states May 20, 2025
@Gargi-jais11 Gargi-jais11 marked this pull request as ready for review May 20, 2025 17:23
Copy link
Contributor

@chungen0126 chungen0126 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Gargi-jais11 for the patch. Left some comments.

@Gargi-jais11 Gargi-jais11 requested a review from chungen0126 May 22, 2025 05:08
Copy link
Contributor

@chungen0126 chungen0126 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 LGTM

@Gargi-jais11 Gargi-jais11 requested a review from ChenSammi May 28, 2025 10:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants