<p>sudo kubeadm init
I0609 02:20:26.963781    3600 version.go:252] remote version is much newer: v1.21.1; falling back to: stable-1.18
W0609 02:20:27.069495    3600 configset.go:202]</p>
<pre><code>WARNING: kubeadm cannot validate component configs `for API groups [kubelet.config.k8s.io kubeproxy.config.k8s.io]`
`[init] Using Kubernetes version: v1.18.19`
`[preflight] Running pre-flight checks`
`error execution phase preflight: [preflight] Some fatal errors occurred:`
`[ERROR Port-10259]: Port 10259 is in use`
`[ERROR Port-10257]: Port 10257 is in use`
`[ERROR FileAvailable--etc-kubernetes-manifests-kube-apiserver.yaml]: `/etc/kubernetes/manifests/kube-apiserver.yaml already exists`
`[ERROR FileAvailable--etc-kubernetes-manifests-kube-controller-manager.yaml]:` `/etc/kubernetes/manifests/kube-controller-manager.yaml already exists`
`[ERROR FileAvailable--etc-kubernetes-manifests-kube-scheduler.yaml]:` /etc/kubernetes/manifests/kube-scheduler.yaml already exists
`[ERROR FileAvailable--etc-kubernetes-manifests-etcd.yaml]: /etc/kubernetes/manifests/etcd.yaml already exists`
`[ERROR Port-10250]: Port 10250 is in use`
`[ERROR Port-2379]: Port 2379 is in use`
`[ERROR Port-2380]: Port 2380 is in use`
`[ERROR DirAvailable--var-lib-etcd]: /var/lib/etcd is not empty`
 [preflight] If you know what you are doing, you can make a check non-fatal with `--ignore-preflight-errors=...`
 To see the stack trace of this error execute with --v=5 or higher
</code></pre>

<p>Hi and welcome to Stack Overflow.</p>
<p><strong>&quot;Port in use&quot;</strong> means that there's a process running that uses that port.  So you need to stop that process. Since you already ran kubeadm init once, it must have already changed a number of things.</p>
<p>First run <strong>kubeadm reset</strong> to undo all of the changes from the first time you ran it.</p>
<p>Then run <strong><strong>systemctl restart</strong> kubelet</strong>.</p>
<p>Finally, when you run <strong>kubeadm init</strong> you should no longer get the error.</p>
<p><strong>Even after following the above steps , if you get this error:</strong></p>
<pre><code>[ERROR DirAvailable--var-lib-etcd]: /var/lib/etcd is not empty
[preflight] If you know what you are doing, you can make a check non-fatal with `--ignore-preflight-errors=...`
</code></pre>
<p>Then, remove the etcd folder (/var/lib/etcd) before you run <strong>kubeadm init</strong>.</p>
<p><strong>Note:</strong></p>
<ol>
<li><p>This <a href="https://www.edureka.co/community/19089/error-while-doing-kubernetes-init-command" rel="nofollow noreferrer">solution</a> worked for other users.</p>
</li>
<li><p>The warning itself is not an issue, it's just warning that kubeadm no longer validates the KubeletConfiguration, KubeProxyConfiguration that it feeds to the kubelet, kube-proxy components.</p>
</li>
</ol>
