Quick Start

Preview Updated: December 1, 2016

  1. Install a Kafka cluster. If you are using open source DC/OS, install a Kafka cluster with the following command from the DC/OS CLI. If you are using Enterprise DC/OS, you may need to follow additional instructions. See the Install and Customize section for more information.
    $ dcos package install kafka
  2. Create a new topic.
    $ dcos kafka topic create topic1
  3. Find connection information.
    $ dcos kafka connection
        "address": [
        "dns": [
        "vip": "broker.kafka.l4lb.thisdcos.directory:9092",
        "zookeeper": "master.mesos:2181/dcos-service-kafka"
  4. Produce and consume data.
    $ dcos node ssh --master-proxy --leader
    core@ip-10-0-6-153 ~ $ docker run -it mesosphere/kafka-client
    root@7d0aed75e582:/bin# echo "Hello, World." | ./kafka-console-producer.sh --broker-list,, --topic topic1
    root@7d0aed75e582:/bin# ./kafka-console-consumer.sh --zookeeper master.mesos:2181/kafka --topic topic1 --from-beginning
    Hello, World.

See also Connecting clients.