<p>What I have zookeeper setup which is running on server1, server2 and server3 and similarly kafka also running in server1, server2 and server3.</p>

<p>Setup are running in kubernetes.</p>

<p><strong>Problem statement:</strong></p>

<ol>
<li><p>In case one zookeeper setup get down entire setup will get down, because kafka is depended to zookeeper. am i right?</p></li>
<li><p>If Q1 correct - Is there any way to make setup like if one zookeeper server will get down then kafka should run as it is?</p></li>
<li><p>How to expose kafka port in kubernetes setup ? </p></li>
<li><p>what is the recommended way to persist data in kubernetes for production server ?</p></li>
</ol>

<p>I fail to see how Zookeeper questions are related to k8s... But you definitely should set affinity rules such that Zookeeper and Kafka are not on the same physical servers or sharing same disks </p>

<p>If one Zookeeper out of three goes down, you'll end up with a split brain event in that no single Zookeeper knows which should be responsible for leadership. This effectively can crash or corrupt Kafka, yes.</p>

<p>To mitigate that risk, you can choose to run 5 Zookeepers, in which case you can lose up to 3 servers to reach the same state. The Definitive Guide book covers these concepts in the first few chapters </p>

<p>Regarding the other questions - NodePorts and PVCs, generally speaking.</p>

<p>Use one of the popular Kafka Operators on Github and you'll not need to think too hard about setting those properties</p>

<p>You still must manually perform Kafka admin tasks in any installation... You can use extra services like Cruise Control if you want to reduce that workload, though </p>
