---
title: "Added a Broker to Apache Kafka? Why It Stays Empty"
description: "Apache Kafka does not move existing partitions to a new broker. The stock commands to fill it, run on 4.3.1, what goes wrong, and where Calinora Pilot fits."
url: "https://www.calinora.io/kafka-add-broker/"
robots: "index, follow"
---

# Added an Apache Kafka® broker? Why it stays empty and how to fill it

Julian Bergner, founder of Calinora\
Updated 2026-10-28\
Stock commands run on Apache Kafka 4.3.1 (KRaft)

Apache Kafka does not move existing partitions to a new broker. The broker joins, takes replicas of new topics, and holds none of your existing data until partitions are moved to it. The stock tool, `kafka-reassign-partitions.sh`, cannot balance load and moves the partitions you list onto the brokers you list, so you have to decide what moves.

## Why a new Apache Kafka broker stays empty

> "However these new servers will not automatically be assigned any data partitions, so unless partitions are moved to them they won’t be doing any work until new topics are created."
>
> [Apache Kafka 4.3 documentation, Expanding your cluster](https://kafka.apache.org/43/operations/basic-kafka-operations/#expanding-your-cluster)

This guide's lab ran Apache Kafka 4.3.1 in KRaft mode: three brokers in racks A, B and C, 42 partitions across three topics, replication factor 3. Broker 4 joined in rack A. After 6 minutes 37 seconds it still held no partition. A topic created after it joined had a replica on broker 4 in 4 of its 8 partitions.

## Add a broker to an Apache Kafka cluster in KRaft mode

A KRaft broker needs its own `node.id`, `process.roles=broker`, listeners, and the controller quorum setting your cluster already uses. The lab's `server.properties` for broker 4:

```properties
process.roles=broker
node.id=4
broker.rack=A
controller.quorum.voters=100@controller:9093
controller.listener.names=CONTROLLER
listeners=PLAINTEXT://:9092,EXTERNAL://:39094
advertised.listeners=PLAINTEXT://broker4:9092,EXTERNAL://localhost:39094
listener.security.protocol.map=CONTROLLER:PLAINTEXT,PLAINTEXT:PLAINTEXT,EXTERNAL:PLAINTEXT
inter.broker.listener.name=PLAINTEXT
log.dirs=/var/lib/kafka/data
```

Before the first start, format its storage with the cluster's id. Skip this and the broker exits with `java.lang.RuntimeException: No readable meta.properties files found.`

```sh
kafka-metadata-quorum.sh --bootstrap-server localhost:9092 describe --status
```

```
ClusterId:              dB4nJkEtSrq3tYr4PgZWVA
...
```

```sh
kafka-storage.sh format -t dB4nJkEtSrq3tYr4PgZWVA -c server.properties
```

```
Bootstrap metadata: BootstrapMetadata(...)
Formatting metadata directory /var/lib/kafka/data with metadata.version 4.3-IV0.
```

```sh
kafka-server-start.sh server.properties
```

```
[2026-10-27 23:08:52,900] INFO [KafkaRaftServer nodeId=4] Kafka Server started (kafka.server.KafkaRaftServer)
```

For a broker that joins an existing cluster, the [Apache Kafka 4.3 KRaft documentation](https://kafka.apache.org/43/operations/kraft/#formatting-brokers-and-new-controllers) adds `--no-initial-controllers` to the format command:

From the Apache Kafka 4.3 docs, not run in the lab

```sh
bin/kafka-storage.sh format --cluster-id <CLUSTER_ID> --config config/server.properties --no-initial-controllers
```

The lab's static quorum worked without the flag. A dynamic quorum uses `controller.quorum.bootstrap.servers` instead of `controller.quorum.voters`.

The official `apache/kafka` Docker image formats the storage itself when configured through environment variables.

Check that the broker joined:

```sh
kafka-broker-api-versions.sh --bootstrap-server localhost:9092 | grep "(id:"
```

```
broker2:9092 (id: 2 rack: B isFenced: false) -> (
broker1:9092 (id: 1 rack: A isFenced: false) -> (
broker3:9092 (id: 3 rack: C isFenced: false) -> (
broker4:9092 (id: 4 rack: A isFenced: false) -> (
```

## Check that the new broker is empty

```sh
kafka-log-dirs.sh --bootstrap-server localhost:9092 --describe --broker-list 4
```

```
Querying brokers for log directories information
Received log directory information from brokers 4
{"brokers":[{"broker":4,"logDirs":[{"partitions":[],"error":null,"logDir":"/var/lib/kafka/data"}]}],"version":1}
```

```sh
kafka-topics.sh --bootstrap-server localhost:9092 --describe | grep -E 'Replicas: [0-9,]*4' | wc -l
```

```
       0
```

The partitions list is empty, and no partition has broker 4 as a replica. Adjust the `grep` pattern to your broker ids.

## Generate a plan with kafka-reassign-partitions.sh

The tool takes two lists: topics to move, as JSON, and the brokers to move them onto.

`topics-to-move.json`:

```json
{"version":1,"topics":[{"topic":"clicks"},{"topic":"orders"},{"topic":"audit"}]}
```

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --topics-to-move-json-file topics-to-move.json --broker-list 1,2,3,4 --generate
```

```
Current partition replica assignment
{"version":1,"partitions":[{"topic":"audit","partition":0,"replicas":[2,3,1],...},...]}

Proposed partition reassignment configuration
{"version":1,"partitions":[{"topic":"audit","partition":0,"replicas":[4,2,3],...},...]}
```

Nothing moves yet. Save the current assignment as your rollback file and the proposed one as `plan.json`.

The [documentation](https://kafka.apache.org/43/operations/basic-kafka-operations/#automatically-migrating-data-to-new-machines) says the tool "evenly distributes all partitions for the given list of topics across the new set of brokers" and keeps the replication factor. It does not weigh load:

> "The partition reassignment tool does not have the capability to automatically study the data distribution in a Kafka cluster and move partitions around to attain an even load distribution."
>
> [Apache Kafka 4.3 documentation, Expanding your cluster](https://kafka.apache.org/43/operations/basic-kafka-operations/#expanding-your-cluster)

## Execute the plan with a throttle, then verify

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --reassignment-json-file plan.json --execute --throttle 5000000
```

```
Current partition replica assignment

{"version":1,"partitions":[{"topic":"audit","partition":0,"replicas":[2,3,1],...}]}

Save this to use as the --reassignment-json-file option during rollback
Warning: You must run --verify periodically, until the reassignment completes, to ensure the throttle is removed.
The inter-broker throttle limit was set to 5000000 B/s
Successfully started partition reassignments for audit-0,audit-1,...,orders-11
```

`--throttle` is in bytes per second, so 5000000 is five million bytes a second. Follow the move with `--list` and `--verify`:

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --list
```

```
Current partition reassignments:
clicks-0: replicas: 3,4,2,1. adding: 4. removing: 1.
clicks-2: replicas: 2,3,4,1. adding: 4. removing: 1.
...
```

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --reassignment-json-file plan.json --verify
```

```
Status of partition reassignment:
Reassignment of partition audit-0 is completed.
...
Reassignment of partition clicks-0 is still in progress.
Reassignment of partition clicks-1 is completed.
...
```

Once every partition has finished, the next `--verify` removes the throttle:

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --reassignment-json-file plan.json --verify
```

```
Status of partition reassignment:
Reassignment of partition audit-0 is completed.
...

Clearing broker-level throttles on brokers 1,2,3,4
Clearing topic-level throttles on topics audit,clicks,orders
```

## Check where the leaders landed

```sh
kafka-topics.sh --bootstrap-server localhost:9092 --describe --topic clicks,orders,audit | grep -o "Leader: [0-9]*" | sort | uniq -c
```

```
   9 Leader: 1
  17 Leader: 2
  15 Leader: 3
   1 Leader: 4
```

A preferred leader election moves leaders back to their preferred replicas, and prints nothing when they already are:

```sh
kafka-leader-election.sh --bootstrap-server localhost:9092 --election-type PREFERRED --all-topic-partitions
```

## Stop a running reassignment

```sh
kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --reassignment-json-file plan-cancel.json --cancel
```

```
Successfully cancelled partition reassignments for: clicks-0,clicks-2,clicks-4,clicks-6
None of the specified partition moves are active.Clearing broker-level throttles on brokers 1,2,3,4
Clearing topic-level throttles on topic clicks
```

Verbatim: the tool prints two messages on the second line, with no space between them.

`--cancel` takes the JSON file of the running reassignment and has existed since Apache Kafka 2.6 (KIP-455). In the lab it removed the partial copies and cleared the throttle. The partitions went back to the same brokers, but three of the four came back in a different replica order, and two of those got a new preferred leader.

## What goes wrong with the stock way

Each of these was seen on the lab cluster:

- **The plan cannot balance load.** `--help` lists no size, load or capacity option. In the lab the plan moved 21 replicas (306,063,283 bytes) and changed 39 of 42 partitions, 18 only by replica order. Brokers 1 and 4 ended close in bytes because partitions within each topic were close in size, not because the tool read sizes.
- **Two runs, two plans.** The same command, run twice in a row, proposed two different plans.
- **It reshuffles what is already in place.** On a test topic with replication factor 2, 9 of 13 new replica placements were copies between the old brokers, and 6 of 11 in a second run. Run again on the rebalanced cluster, the tool proposed changing all 42 partitions and copying 203,542,288 bytes, for no gain in balance.
- **The rack layout decides what can move.** Rack awareness is on by default when brokers set `broker.rack`; with three racks and replication factor 3, every partition keeps a replica in each rack. The lab's new broker shared rack A with broker 1, so all 21 moves came off broker 1, and brokers 2 and 3 kept about twice the bytes of brokers 1 and 4. That follows from the lab's layout, not from rack awareness in general. `--disable-rack-aware` evened the bytes but needed 32 moves and left 21 partitions with two replicas in one rack.
- **The throttle outlives the move.** It stays on until someone runs `--verify` after the last move finishes; `--verify --preserve-throttles` leaves it in place. The [documentation](https://kafka.apache.org/43/operations/basic-kafka-operations/#limiting-bandwidth-usage-during-data-migration) warns that a throttle left behind "could cause regular replication traffic to be throttled."
- **Progress has no bytes or time.** `--verify` and `--list` report per partition, with no bytes, percent done or time left.
- **Leaders lag behind and stay uneven.** Right after the move, broker 4 led 1 of 42 partitions, though the plan made it the preferred leader of 7. About two minutes later, with no leader election command run, leaders moved to their preferred replicas. That fits Kafka's default `auto.leader.rebalance.enable=true` (checked every 300 seconds). Even then, the executed plan made brokers 1 to 4 the preferred leaders of 9, 13, 13 and 7 partitions, and a preferred election only restores that order.

## Where Calinora Pilot fits

Calinora Pilot, partition rebalancing for Apache Kafka, writes the plan the stock tool leaves to you.

**Free: Pilot tells you what to move. Licensed: Pilot moves it safely.**

**Where Calinora Pilot fits**

| | kafka-reassign-partitions.sh | Calinora Pilot |
| - | - | - |
| Decides what moves | You, by listing topics and brokers | Pilot, with a reason on every move |
| Input | Topic and broker lists, no size or load | Observed load: leaders, replicas, disk, produce and consume rates |
| Replication throttle | Stays on until someone runs `--verify` after the last move finishes | Set before the first move and cleared after |

### Free: what to move, where, and why

Pilot connects with your bootstrap servers plus the client security settings you already use, and never reads your messages to monitor. It compares every broker with its fair share of observed load: leaders, replicas, disk, produce and consume rates. By default, when a broker stays more than 10% from its fair share, the plan evens it to within 5%. A new, empty broker is filled in one plan.

Every move carries a reason, and balance plans are rack-aware by default. When a broker cannot get closer, Pilot says so, with the cause and what would help. The same cluster snapshot and settings produce the same plan, and the plan you review is the plan that runs.

### Licensed: the move, throttled and checked

Applying a plan needs a license. When you apply one, Pilot checks the cluster first and stops at a hard-health blocker: no controller, an unreachable controller, a majority of brokers unavailable, or a sustained ISR shrink. No operator can override one. A managed replication throttle, on by default at 50 MB/s, is set before the first move and cleared after, so there is no `--verify` to remember. Cancel stops the remaining work, through Kafka's own cancel.

[How it works](https://www.calinora.io/products/pilot/#how-it-works)

## Questions about adding Apache Kafka brokers

### Does cordoning in Apache Kafka 4.3 move partitions to a new broker?

No. Cordoning (KIP-1066, new in 4.3) stops new partitions from being placed on a cordoned log directory or broker. Replicas already there stay where they are.

### Does auto.leader.rebalance.enable move data to the new broker?

No. It moves leadership only, back to each partition's preferred replica. Replicas stay where they are.

### My new brokers are bigger than the old ones. Does Pilot give them more?

Not yet. Fair shares do not depend on broker hardware today, so give every broker room for its fair share.

### Does Pilot change anything on my cluster when I run it free?

Pilot moves partitions only when someone applies a plan; scheduled repairs are off unless you turn them on. Both need a license, so a free install moves no partitions. It does create up to four topics of its own: broker state, the audit log, the cluster conditions, and access tokens when tokens are turned on. And with the default `PILOT_THROTTLE_MANAGED=true`, it removes at startup the replication throttles an earlier run of Pilot set, once Kafka lists no reassignment in progress. Throttles that `kafka-reassign-partitions.sh` or a person set stay as they are.

[What Pilot changes on your cluster](https://www.calinora.io/products/pilot/#changes)

## See the plan for your new broker

See which partitions Pilot would move to your new broker, and why, before anything moves.

[Run it free on your cluster](https://docs.calinora.io/getting-started/quickstart)

[See pricing](https://www.calinora.io/pricing/) · [Talk to us](https://www.calinora.io/products/pilot/#contact)
