<p>I was having K3s cluster with below pods running:</p>
<pre><code>kube-system   pod/calico-node-xxxx                          
kube-system   pod/calico-kube-controllers-xxxxxx   
kube-system   pod/metrics-server-xxxxx
kube-system   pod/local-path-provisioner-xxxxx
kube-system   pod/coredns-xxxxx
xyz-system    pod/some-app-xxx
xyz-system    pod/some-app-db-xxx
</code></pre>
<p>I want to stop all of the K3s pods &amp; reset the containerd state, so I used <a href="https://rancher.com/docs/k3s/latest/en/upgrades/killall/" rel="noreferrer">/usr/local/bin/k3s-killall.sh</a> script and all pods got stopped (at least I was not able to see anything in <code>watch kubectl get all -A</code> except <code>The connection to the server 127.0.0.1:6443 was refused - did you specify the right host or port?</code> message)</p>
<p>Can someone tell me how to start the k3s server up because now after firing <code>kubectl get all -A</code> I am getting message <code>The connection to the server 127.0.0.1:6443 was refused - did you specify the right host or port?</code></p>
<p><strong>PS:</strong></p>
<ul>
<li>When I ran <code>k3s server</code> command, for fraction of seconds I can see the same above pods(with same pod ids) that I mentioned while the command is running. After few seconds, command get exited and again same message <code>The connection to the...</code> start displaying.</li>
</ul>
<p>Does this means that <code>k3s-killall.sh</code> have not deleted my pods as it is showing the same pods with same ids ( like <code>pod/some-app-xxx</code> ) ?</p>

Thor
<ol>
<li><p>I think you need to restart K3s via systemd if you want your cluster back after kill. Try command:  <br/><code>sudo systemctl restart k3s</code>
This is supported by the installation script for systemd and openrc. Refer <a href="https://www.rancher.co.jp/docs/k3s/latest/en/running/" rel="noreferrer">rancher doc</a></p>
</li>
<li><p>The pod-xxx id will remain same as k3s-killall.sh doesn't uninstall k3s (you can verify this, after k3s-killall script <code>k3s -v</code> will return output) and it only restart the pods with same image. The <code>Restarts</code> column will increase the count of all pods.</p>
</li>
</ol>
