# Kubectl connection refused

**URL:** <https://discuss.kubernetes.io/t/kubectl-connection-refused/15841>\
**Category:** General Discussions\
**Created:** [May 10, 2021, 9:03am UTC](https://discuss.kubernetes.io/t/kubectl-connection-refused/15841 "2021-05-10T09:03:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![cmd](https://avatars.discourse-cdn.com/v4/letter/c/dbc845/32.png) [@cmd](https://discuss.kubernetes.io/u/cmd)\
**Post date:** [May 10, 2021, 9:03am UTC](https://discuss.kubernetes.io/t/kubectl-connection-refused/15841/1 "2021-05-10T09:03:30Z")

</div>

Hello all.

Hope someone can help me.  
To describe the situation in short, I have a self managed k8s cluster, running on 3 machines (1 master, 2 worker nodes). In order to make it HA, I attempted to add a second master to the cluster.  
After some failed attempts, I found out that I needed to add controlPlaneEndpoint configuration to kubeadm-config config map. So I did, with masternodeHostname:6443.

I generated the certificate and join command for the second master, and after running it on the second master machine, it failed with  
error execution phase control-plane-join/etcd: error creating local etcd static pod manifest file: timeout waiting for etcd cluster to be available  
Checking the first master now, I get connection refused for the IP on port 6443. So I cannot run any kubectl commands.  
Tried recreating the .kube folder, with all the config copied there, no luck.  
Restarted kubelet, docker.  
The containers running on the cluster seem ok, but I am locked out of any cluster configuration (dashboard is down, kubectl commands not working).  
Is there any way I make it work again? Not losing any of the configuration or the deployments already present?  
Thanks! Sorry if it’s a noob question.

### Cluster information:

Kubernetes version: 1.15.3  
Cloud being used: (put bare-metal if not on a public cloud) bare-metal  
Installation method: kubeadm  
Host OS: RHEL 7  
CNI and version: weave 0.3.0  
CRI and version: containerd 1.2.6
