<p>Is there any way to rename a replication controller for it to be picked up by the rolling update command  ?</p>

<p>The problem is my rolling update failed in the middle with the below error :</p>

<blockquote>
  <p>Renaming xx to xx-353rfdf44</p>
  
  <p>Error from server: client: etcd cluster is unavailable or
  misconfigured; error #0: read tcp
  172.17.22.102:55398->172.17.22.102:4001: read: connection reset by peer</p>
</blockquote>

<p>First of all I dont know why this happend. And second, as you can see, it failed in the rename step. So my rolling update java code, when executed is looking for xx Replication Controller to perform rolling update and since now it is called xx-353rfdf44 , it is not able to find it.</p>

<p>I was wondering if I can do a manual fix to rename xx-353rfdf44 back to xx for my rolling update java code to work again.</p>

<p>Thanks in advance</p>

user1722908
<p>According to <a href="https://kubernetes.io/docs/tasks/run-application/rolling-update-replication-controller/" rel="nofollow noreferrer">Perform Rolling Update Using a Replication Controller</a> document:</p>

<p>When rolling update is started, it creates a new replication controller(RC) with updated configuration, then it decreases the number of replicas for the old RC and increases the number of replicas for the new RC until the old RC reaches 0 replicas, and the new RC reaches desired number of replicas. Finally, rolling update deletes the old RC.</p>

<p>There is no way to rename objects in Kubernetes because the name of the object is used as an identifier. <a href="https://stackoverflow.com/a/39428753/9521610">SO Answer</a></p>

<p>In your case, it would be better to operate on the level of Deployment object because when rolling update is started for the deployment, it doesn't recreate the deployment object and therefore its name does not change.</p>
