- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Kafka broker bind to 0.0.0.0
Created on 08-05-2016 02:36 AM - edited 09-16-2022 03:33 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Currently we have deployed a kafka service over CDH 5.7.2. Our cluster has two interfaces per host. One for remote access and another one for cluster intra-communication.
Everything is working properly if we access through internal cluster ports. However, we cannot access from external interfaces. Ports are closed. Kafka only binds to internal ports.
In order to bind to external ports, we should use host.name environment. However, Cloudera Manager does not allow to use environment variables with a dot (host.name) in it. Is there any way to surpass this limitation??
We have also got kafka to bind all IPs by modifiying listerners=PLAINTEXT://0.0.0.0 parameter, but the problem in this case is that zookeeper takes 0.0.0.0 as broker name and so it cannot be resolved at client.
Meanwhile, we have used iptables in order to forward traffic to port 9092 at external interface to internal interface, but this is not the way we should proceed.
Any hint about using host.name parameter?
Thanks in advance.
Created 11-21-2016 01:46 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
You can do the following step:
Kafka > Instances (Select Instance) > Configuration > Kafka Broker > Advanced > Kafka Broker Advanced Configuration Snippet (Safety Valve) for kafka.properties
Please add (example):
listeners=PLAINTEXT://192.10.0.1:9092,PLAINTEXT://10.0.3.3:9092
Gabor
