mc admin rebalance

Permission

This command requires that the user performing it have the admin:Rebalance policy action for the deployment.

Description

The mc admin rebalance command allows starts, monitors, or stops a rebalancing operation on a AIStor deployment. Rebalancing redistributes objects across all pools in the deployment.

AIStor does not automatically rebalance objects when adding a new server pool. Instead, AIStor writes new objects to the pool with relatively more free space compared to the other available pools on the deployment. Triggering a manual rebalancing procedure prompts AIStor to scan the entire deployment and move objects as necessary to achieve a similar available free space across all pools.

This is an expensive and time consuming operation. Consider only running a rebalance procedure during light or no use of the deployment. If write operations do occur during a rebalance operation, they process in parallel and write to a pool not actively in rebalancing.

You can stop a rebalance and start it again later as needed.

Follow the progress of an ongoing rebalance operation using the following command:

mc admin trace --call rebalance ALIAS

The mc admin rebalance command has the following subcommands:

Subcommand Description
mc admin rebalance start Starts a rebalance operation on a AIStor deployment.
mc admin rebalance status Outputs the current status of an in-progress rebalance operation.
mc admin rebalance stop Stops an in-progress rebalance operation.

Syntax

mc admin rebalance start

Start a rebalance operation for a AIStor deployment.

EXAMPLES

Consider a AIStor deployment with two pools with an assigned alias of minio1. One pool has 250 GB of free space while the other pool has 3 TB of free space.

The mc admin rebalance command shifts objects from the pool with less free space to the pool with more free space so that there is roughly equal free space on both pools.

mc admin rebalance start minio1

SYNTAX

The command has the following syntax:

mc [GLOBALFLAGS] admin rebalance start ALIAS
  • Replace ALIAS with the alias of a AIStor deployment to rebalance.

mc admin rebalance status

Queries the deployment with an active rebalance process and returns information about the status of the rebalance process.

The status returns the ID of the rebalance operation, the time of the operation, and details for each pool on the deployment. For each pool, the status shows the pool ID, the pool’s rebalance status, the percentage of used space, and rebalance progress for the pool.

EXAMPLE

mc admin rebalance status minio1

SYNTAX

The command has the following syntax:

mc [GLOBALFLAGS] admin rebalance ALIAS
  • Replace ALIAS with the alias of the AIStor deployment.

mc admin rebalance stop

Ends an in-progress rebalance job on the specified deployment.

EXAMPLES

mc admin rebalance stop minio1

SYNTAX

The command has the following syntax:

mc [GLOBALFLAGS] admin rebalance stop ALIAS
  • Replace ALIAS with the alias of the AIStor deployment.

Global Flags

This command supports any of the global flags.

Behavior

Back Up Cluster Settings First

Use the mc admin cluster bucket export and mc admin cluster iam export commands to take a snapshot of the bucket metadata and IAM configurations respectively prior to starting decommissioning. You can use these snapshots to restore bucket/IAM settings to recover from user or process errors as necessary.

Rebalancing Ignores Expired Objects and Trailing DeleteMarker

Rebalancing ignores object versions which have expired based on the configured lifecycle rules for the parent bucket.

Rebalancing also ignores objects where the only remaining version is a delete marker. This avoids inter-pool for objects already considered fully deleted.

AIStor relies on the scanner to capture and remove those expired objects or trailing DeleteMarker objects.

All rights reserved 2024-Present, MinIO, Inc.