<p>I have a statefulset having <code>2</code> replicas and I want to increase the storage in each of the pods from <code>300GB</code> to <code>3TB</code>. So I edited the statefulset to increase the storage.</p>
<p>But this doesn't get reflected directly. I plan to do a rollout restart using the command of type:</p>
<p><code>kubectl rollout restart statefulset my-statefulset</code></p>
<p>But I am not sure if this will create Pods with fresh volume or if there is an easy way to ensure that it transfers the old data of <code>300GB</code> to the volume of <code>3TB</code>.</p>
<p>I am using GKE.</p>
<p>Client Version: v1.16.1</p>
<p>Server Version: v1.14.10-gke.42</p>

<p>There is way expand volumes . Steps in brief</p>
<ol>
<li>Your storage class should have allowVolumeExpansion field to true and provisioner should support it (in case of GKE if your volumes are provisioned with provisioner: kubernetes.io/gce-pd this will work).</li>
<li>Edit the storage  in PVC ( remember you can only expand the volume and not shrink it)</li>
<li>After you edit it will wait for pod restart for the expansion to take place. Once pod restarts it will expand the volume.</li>
</ol>
<p>Reference Doc : <a href="https://kubernetes.io/blog/2018/07/12/resizing-persistent-volumes-using-kubernetes/" rel="nofollow noreferrer">here</a></p>
