# 2021-05-14-02:00:00+0800 replace cloudchat tidb machine type

- Cause: Replace tidb machine type, [ticket](https://pingcap.zendesk.com/agent/tickets/195)
- Operation: execute the following commands

```

kubectl taint node -l  gardener.node.machine.type=c5.9xlarge,gardener.wg.prefix.name=tidb1311285575352848384-tidb memory=toobig:NoSchedule

k edit tc db -n tidb1311285575352848384
   tidb:
     annotations:
       rollingrestart: "true"
       tidb.pingcap.com/sysctl-init: "true"
check connection by monitor

kubectl get machines -n shoot--prod--4bc76ea  -o custom-columns=Annotations:.metadata.annotations,Name:.metadata.name,nodeTemplate:.spec.nodeTemplate.metadata.labels.gardener\\.node\\.machine\\.type,NodeName:.metadata.labels.node | grep machinepriority.machine.sapcloud.io:0 | grep c5.4xlarge | awk '{print $2}' | while read m; do kubectl  annotate  --overwrite  machines $m machinepriority.machine.sapcloud.io=3 -n shoot--prod--4bc76ea; done

kubectl edit shoot 4bc76ea -n garden-prod //delete c5.9xlarge tidb workergroup
         			 
```

- Impact: The tidb pods are rollingupdate
- Recovery operation: No

- Time window: 02:00 PM, 2021 May 14 ~ 02:20 PM, 2021 May 14