<p>I do not want to decrease the number of pods controlled by StatefulSet, and i think that decreasing pods is a dangerous operation in production env.</p>

<p>so... , is there some way ? thx ~</p>

adrian ding
<p>I'm not sure if this is what you are looking for but you can <a href="https://kubernetes.io/docs/tasks/run-application/scale-stateful-set/" rel="nofollow noreferrer">scale a StatefulSet</a></p>

<blockquote>
  <h3>Use kubectl to scale StatefulSets<a href="https://kubernetes.io/docs/tasks/run-application/scale-stateful-set/#use-kubectl-to-scale-statefulsets" rel="nofollow noreferrer"></a></h3>
  
  <p>First, find the StatefulSet you want to scale.</p>
  
  <pre class="lang-sh prettyprint-override"><code>kubectl get statefulsets &lt;stateful-set-name&gt;
</code></pre>
  
  <p>Change the number of replicas of your StatefulSet:</p>
  
  <pre class="lang-sh prettyprint-override"><code>kubectl scale statefulsets &lt;stateful-set-name&gt; --replicas=&lt;new-replicas&gt;
</code></pre>
</blockquote>

<p>To show you an example, I've deployed a 2 pod StatefulSet called <code>web</code>:</p>

<pre><code>$ kubectl get statefulsets.apps web 
NAME   READY   AGE
web    2/2     60s
$ kubectl get pods
NAME    READY   STATUS    RESTARTS   AGE
web-0   1/1     Running   0          63s
web-1   1/1     Running   0          44s

$ kubectl describe statefulsets.apps web
Name:               web
Namespace:          default
CreationTimestamp:  Wed, 23 Oct 2019 13:46:33 +0200
Selector:           app=nginx
Labels:             &lt;none&gt;
Annotations:        kubectl.kubernetes.io/last-applied-configuration:
                      {"apiVersion":"apps/v1","kind":"StatefulSet","metadata":{"annotations":{},"name":"web","namespace":"default"},"spec":{"replicas":2,"select...
Replicas:           824643442664 desired | 2 total
Update Strategy:    RollingUpdate
  Partition:        824643442984
Pods Status:        2 Running / 0 Waiting / 0 Succeeded / 0 Failed
...
</code></pre>

<p>Now if we do scale this StatefulSet up to 5 replicas:</p>

<pre><code>$ kubectl scale statefulset web --replicas=5
statefulset.apps/web scaled

$ kubectl get pods
NAME    READY   STATUS    RESTARTS   AGE
web-0   1/1     Running   0          3m41s
web-1   1/1     Running   0          3m22s
web-2   1/1     Running   0          59s
web-3   1/1     Running   0          40s
web-4   1/1     Running   0          27s

$ kubectl get statefulsets.apps web
NAME   READY   AGE
web    5/5     3m56s
</code></pre>

<p>You do not have any downtime in already working pods.</p>
