-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Still connecting to unix:///... #139
Comments
It seems that it's not possible to get an ID. It's calling http://169.254.169.254/2009-04-04/meta-data/instance-id (hardcoded in code). But it's not reachable. Means: It cannot be reached from the k8s-nodes within the private network. It's only reachable from the nodes which have a public interface. |
#131 |
Okay.... That seems to be a way. I'm not happy with it. Opening a door always make it accessible from both sides. But it's just a small one... :( |
@eBeyond try to use the current master deployment :) there is a small change in there which first uses the node name for getting the data. https://github.com/hetznercloud/csi-driver/blob/master/deploy/kubernetes/hcloud-csi-master.yml |
I've tried the hcloud-csi-master, but it didn't succeed. Now I've tried it with the route and it work as expected. Thanks! |
Actually it should work, do the nodes in k8s have the same name as in the Cloud Console? Did you apply the new deployment? |
I have Kubernetes 1.18.0 running on CX21 instances with Ubuntu 18.04. Following the quick guide I created the secret, deployed the latest hcloud-csi-master.yml. Deployment of the containers does not give any issue, but from the logs of the pod:
Same for the controller and the other nodes, just like @eBeyond explained |
@JWDobken what does the controller say? |
|
@JWDobken the controller pod log more than just this (likely after it started). |
Full output of the controller just after launch:
|
It doesn't looks like you are using the latest "master", as it tries to use the metadata service (which is not possible for your setup based on your comments in #131). Please use: https://github.com/hetznercloud/csi-driver/blob/master/deploy/kubernetes/hcloud-csi-master.yml |
Instead of this line from the quickstart:
I run:
Logs of the controller:
|
btw, if I change
and restart the service networking:
|
Managed to resolve it by checking:
At this point, I compared iptables rules between nodes that were working vs. ones that weren't. I noticed in the non-working ones:
So I ran Related kubernetes/kubernetes#40182 |
I have exactly the same issue with 1.4.0 and kubelet 1.17.9 (from rancher) as described here. Nor the suggestion above, nor the yaml file from master helped. I had the exact same setup before and it worked. They only change I made on this new cluster, is using Weave for networking. |
Same for me with the following setup:
Since I can recreate my cluster from scratch (including recreating VMs, using ansible) within ~40 minutes, I redeployed numerous times and this behavior is reproduced everytime. Remarkable - the
while
Remarkable - of the 5
I'm clueless where else to look. P.S.: I also tried with master but the behavior is exactly the same. |
Just had same issue. In my case metadata service wasn't accessible inside of pod, and I'm also having NAT-like setup. While hcloud-csi-node are getting instance IDs from their name, controlled doesn't as it doesn't have KUBE_NODE_NAME variable. Modifying deployment file and adding new env. variable fixed this issue for me. PR: #144 |
No luck for me. Still getting the same error even with the above PR merged. Logs from 'hcloud-csi-driver'
|
@mehdisadeghi looks like the lookup using the name was not possible (the node name in k8s is different from the name in the hcloud cloud console) and then the lookup by the meta data service also failed. I guess there is something wrong with your network. |
@LKaemmerling thanks for the tip. The hostnames on both nodes (the control plane and the only worker) are exactly the same as the hostnames on hcloud console (as I can see under my servers list and using hostname command on the nodes). The cluster is also a vanilla cluster created using rancher based on Ubuntu 18.04 images with Weave networking. |
Could you make sure that you can access https://api.hetzner.cloud (Maybe just a curl within a pod)? It looks like the network doesn't work correctly. |
@LKaemmerling in order to move Weave out of the equation, I just upgraded my rancher image to the latest version (rancher/rancher:latest - released 18 hours ago), created a new cluster with one control-plane node (etcd, control plane) and one worker node (both CPX21). With K8s v1.18.6-rancher1-2 with Canal networking (rancher's default) with docker v19.03. Then I applied my secret and then the csi-driver yaml declarations on the master branch. Still similar errors, which look like a go runtime error:
I also deployed a pod and I can access the api within the pod (even though I get a TLS error, because the dnsutils pod does not come with necessary certificates):
FWIW all the nodes are connected over a private network. |
I think the issue is because of rancher-provided kubernetes. I have read hcloud-csi and found out that it use to mount |
@vlasov-y interesting point. I checked the nodes and infact
There is this |
I am setting cluster with plain kubeadm and try running hcloud-csi. Will reply there about the results. |
The same result... Setting up of cluster using kubeadm and v1.18.8 produce the same result |
@vlasov-y good to know that! In that case this ticket should be reopened. |
Hello @mehdisadeghi. I had an error in secrets configuration. I have fixed it and now it works!
Solution in my case was migration from k3s.io to standard kubeadm. Issue should be in:
|
Thanks for the update @vlasov-y. I'll try to see whether I can fix that, however in that case it should be noted in the README that hetznercloud csi-driver does not work with Rancher-based clusters. |
I hardcoded my server ID in csi-driver source code, built and ran the csi-driver image locally and realized the token I was using belonged to a different project on Hetzner and not the one running the Rancher VMs. After using the right token everything worked as expected. My carelessness aside, some less cryptic error message would have gone a long way. Thanks. |
@intdel I also face this issue. Would be great to know what incoming ports need to be allowed for the csi-driver to work. |
@intdel You have to allow incoming UDP Port 8472 |
This is a rather popular issue, so just in case other people end up here while searching for the error message: Please don't allow public access to 8472, we sorted that out in #204 (comment). |
Hello, I was struggling with the same problem. My solution were, I forgot to install the following packages
Install command: After it, the connection issue disappeared. Regards |
In our case, it was just because the We just changed the image tag with the stable version and it was fixed. |
I had this issue with a new node from a different hetzner cloud project. Worked fine after assigning the VM to the right project. |
Two years are gone and I had the same issue. Came back to this thread. Read supportive community comments and finally my own commands to realize that, well... I have made the same mistake of using the wrong hcloud token in a wrong project. I guess I'm not getting younger. The morale of the story, it is good to write descriptive comments and contribute even if it is reporting errors. |
Came here again after a while. api.hetzner.cloud was resolving to a wrong ip. Solution was adding the linked ndots to the csi-controller deployment. |
The hcloud-csi nodes and the controller are in Crashloops after istalling hcloud-csi as described.
The hcloud-csi-driver reports:
level=debug ts=2020-08-07T05:42:01.694472148Z msg="getting instance id from metadata service"
All other pods of the hcloud-csi-controller reporting:
Still connecting to unix:///var/lib/csi/sockets/pluginproxy/csi.sock
The pods of the hcloud-csi-nodes are reporting (except the hcloud-csi-driver, which reports the same mentioned above):
Still connecting to unix:///csi/csi.sock
It's a k8s 1.18.6 running in nbg-dc3 on private networks only. All of them have no public network-interfaces but having a firewall with nat allowed for everything. ipv6 is disabled for all nodes.
The text was updated successfully, but these errors were encountered: