GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Pulsar Standalone 4.2.5: BookKeeper Connects to Stale Container IP After Restart, Ledger Recovery Fails · apache/pulsar · Discussion #26992

Pulsar Standalone 4.2.5: BookKeeper Connects to Stale Container IP After Restart, Ledger Recovery Fails #26992

Answered by lhotari
PudgeJ asked this question in Q&A
Pulsar Standalone 4.2.5: BookKeeper Connects to Stale Container IP After Restart, Ledger Recovery Fails #26992
@PudgeJ PudgeJ
Oct 19, 2026 · 1 comments · 1 reply
Answered by lhotari Return to top
Discussion options
  • Uh oh!

    There was an error while loading. Please reload this page.

PudgeJ
Oct 19, 2026

Environment

Apache Pulsar: 4.2.5

Deployment: Docker Compose

Mode: Standalone (bin/pulsar standalone)

Storage: Persistent Docker volume mounted at /pulsar/data

Operating system: macOS with Docker Desktop

Network: Docker bridge network

Problem description

I'm running Apache Pulsar 4.2.5 in standalone mode using Docker Compose. After restarting the container or changing its network configuration, BookKeeper attempts to connect to a stale container IP address (172.19.0.3:46565).

This causes the managed ledger for persistent://public/functions/__change_events to fail to open and recover.

The container can start successfully when I explicitly assign the old IP address 172.19.0.3, but I would prefer not to hardcode a container IP in Docker Compose.

pulsar:
container_name: apache-pulsar
image: apachepulsar/pulsar:4.2.5
command: ["bin/pulsar", "standalone"]
hostname: pulsar
ports:
- "9090:8080"
- "6650:6650"
volumes:
- pulsar_data:/pulsar/data
- ./pulsar/connectors:/pulsar/connectors
- ./pulsar/sources:/pulsar/sources
- ./pulsar/functions:/pulsar/functions
- ./pulsar/data/logs:/pulsar/logs:z
restart: unless-stopped
networks:
caotang-net:
ipv4_address: 172.19.0.3。 -- The container can start successfully when I explicitly assign the old IP address 172.19.0.3, but I would prefer not to hardcode a container IP in Docker Compose.

You must be logged in to vote
All reactions
Answered by lhotari Oct 19, 2026

Pulsar standalone has been tied to the IP address in the past due to not using BK cookie IDs. In master / branch-5.0, this was addressed by #25694 and #26790. Unfortunately it is not possible to convert data from a previous installation to make it decoupled from the IP addresses. When upgrading to Pulsar 5.x when existing data exists, it will take the legacy path which is tied to the IP addresses.

Could you start with scratch with apachepulsar/pulsar:5.0.0 image?

View full answer

Replies: 1 comment · 1 reply

Comment options
  • Uh oh!

    There was an error while loading. Please reload this page.

  • Uh oh!

    There was an error while loading. Please reload this page.

lhotari
Oct 19, 2026
Collaborator

Pulsar standalone has been tied to the IP address in the past due to not using BK cookie IDs. In master / branch-5.0, this was addressed by #25694 and #26790. Unfortunately it is not possible to convert data from a previous installation to make it decoupled from the IP addresses. When upgrading to Pulsar 5.x when existing data exists, it will take the legacy path which is tied to the IP addresses.

Could you start with scratch with apachepulsar/pulsar:5.0.0 image?

You must be logged in to vote
All reactions
1 reply
@PudgeJ
Comment options
  • Uh oh!

    There was an error while loading. Please reload this page.

PudgeJ Oct 20, 2026
Author

Thanks for the explanation.

I would like to clarify whether my existing Pulsar Standalone data is still recoverable.

I also tried upgrading to Pulsar 5.0.0 while reusing my existing data, but the data still could not be recovered. The original topics and messages were not loaded as expected.

Based on your explanation, does this mean that my existing data cannot be converted to use the new BookKeeper cookie IDs, and that the recommended approach is to abandon the old data and start from scratch with Pulsar 5.0.0?

If so, for a fresh Pulsar Standalone instance, should I use the following Docker Compose configuration?

image: apachepulsar/pulsar:5.0.0
command: ["bin/pulsar", "standalone", "--advertised-address", "localhost"]
environment:
  PULSAR_STANDALONE_USE_ZOOKEEPER: "1"

I understand that this would be a fresh installation with a new, empty data directory.

Could you please confirm whether this is the recommended setup for Pulsar 5.0.0 Standalone, and whether there is any supported way to recover or migrate my existing topics, messages, and subscriptions before I abandon the old data?

Thank you for your help.

All reactions
Answer selected by lhotari
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
🙏
Q&A
Labels
None yet
2 participants
@PudgeJ @lhotari
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.