<p>In <a href="https://github.com/kubernetes/kubernetes/blob/release-1.1/examples/elasticsearch/production_cluster/README.md" rel="nofollow">the Kubernetes example of Elasticsearch production deployment</a>, there is a warning about using <code>emptyDir</code>, and advises to "be adapted according to your storage needs", which is linked to the documentation of persistent storage on Kubernetes.</p>

<p>Is it better to use a persistent storage, which is an external storage for the node, and so needs (high) I/O over network, or can we deploy a reliable Elasticsearch using multiple data nodes with local <code>emptyDir</code> storage?</p>

<p>Context: We're deploying our Kubernetes on commodity hardware, and we prefer not to use SAN for the storage layer (because it doesn't seem like commodity).</p>

Reza Mohammadi
<p>The warning is so that folks don't assume that using <code>emptyDir</code> provides a persistent storage layer. An <code>emptyDir</code> volume will persist as long as the pod is running on the same host. But if the host is replaced or it's disk becomes corrupted, then all data would be lost. Using network mounted storage is one way to work around both of these failure modes. If you want to use replicated storage instead, that works as well. </p>
