Updating distribution directories wrt RKE, RKE2, K3s. Verified across distribution versions and updated in the docs across versions/i18n.

Signed-off-by: Sunil Singh <sunil.singh@suse.com>
This commit is contained in:
Sunil Singh
2025-05-27 12:01:07 -07:00
parent 988c958747
commit 5512ce8360
14 changed files with 1637 additions and 197 deletions
@@ -243,23 +243,30 @@ sudo k3s-uninstall.sh
The following directories are used when adding a node to a cluster, and should be removed. You can remove a directory using `rm -rf /directory_name`.
:::important
Depending on the role you assigned to the node, certain directories may or may not be present on the node.
:::
<Tabs>
<TabItem value="RKE1">
| Directories |
|------------------------------|
| `/etc/ceph` |
| `/etc/cni` |
| `/etc/kubernetes` |
| `/etc/rancher` |
| `/opt/cni` |
| `/opt/rke` |
| `/run/calico` |
| `/run/flannel` |
| `/run/secrets/kubernetes.io` |
| `/var/lib/calico` |
| `/var/lib/cni` |
| `/var/lib/etcd` |
| `/var/lib/kubelet` |
| `/var/lib/rancher` |
| `/var/lib/rancher/rke` |
| `/var/lib/weave` |
| `/var/log/containers` |
| `/var/log/kube-audit` |
| `/var/log/pods` |
@@ -271,21 +278,120 @@ Depending on the role you assigned to the node, certain directories may or may n
rm -rf /etc/ceph \
/etc/cni \
/etc/kubernetes \
/etc/rancher \
/opt/cni \
/opt/rke \
/run/calico \
/run/flannel \
/run/secrets/kubernetes.io \
/var/lib/calico \
/var/lib/cni \
/var/lib/etcd \
/var/lib/kubelet \
/var/lib/rancher\
/var/lib/rancher/rke \
/var/lib/weave \
/var/log/containers \
/var/log/kube-audit \
/var/log/pods \
/var/run/calico
```
</TabItem>
<TabItem value="RKE2">
| Directories |
|------------------------------|
| `/etc/ceph` |
| `/etc/cni` |
| `/etc/kubernetes` |
| `/etc/rancher` |
| `/opt/cni` |
| `/run/calico` |
| `/run/flannel` |
| `/run/secrets/kubernetes.io` |
| `/var/lib/calico` |
| `/var/lib/cni` |
| `/var/lib/etcd` |
| `/var/lib/kubelet` |
| `/var/lib/rancher` |
| `/var/lib/weave` |
| `/var/log/containers` |
| `/var/log/pods` |
| `/var/run/calico` |
**To clean the directories:**
```shell
rm -rf /etc/ceph \
/etc/cni \
/etc/kubernetes \
/etc/rancher \
/opt/cni \
/run/calico \
/run/flannel \
/run/secrets/kubernetes.io \
/var/lib/calico \
/var/lib/cni \
/var/lib/etcd \
/var/lib/kubelet \
/var/lib/rancher \
/var/lib/weave \
/var/log/containers \
/var/log/pods \
/var/run/calico
```
</TabItem>
<TabItem value="K3s">
| Directories |
|------------------------------|
| `/etc/ceph` |
| `/etc/cni` |
| `/etc/kubernetes` |
| `/etc/rancher` |
| `/etc/systemd/system/k3s` |
| `/opt/cni` |
| `/run/calico` |
| `/run/flannel` |
| `/run/secrets/kubernetes.io` |
| `/usr/local/bin/k3s` |
| `/var/lib/calico` |
| `/var/lib/cni` |
| `/var/lib/etcd` |
| `/var/lib/kubelet` |
| `/var/lib/rancher` |
| `/var/lib/weave` |
| `/var/log/containers` |
| `/var/log/pods` |
| `/var/run/calico` |
**To clean the directories:**
```shell
rm -rf /etc/ceph \
/etc/cni \
/etc/kubernetes \
/etc/rancher \
/etc/systemd/system/k3s \
/opt/cni \
/run/calico \
/run/flannel \
/run/secrets/kubernetes.io \
/usr/local/bin/k3s \
/var/lib/calico \
/var/lib/cni \
/var/lib/etcd \
/var/lib/kubelet \
/var/lib/rancher \
/var/lib/weave \
/var/log/containers \
/var/log/pods \
/var/run/calico
```
</TabItem>
</Tabs>
### Network Interfaces and Iptables
The remaining two components that are changed/configured are (virtual) network interfaces and iptables rules. Both are non-persistent to the node, meaning that they will be cleared after a restart of the node. To remove these components, a restart is recommended.