-
Notifications
You must be signed in to change notification settings - Fork 32
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
locksmith fails when -etcd-cafile is specified #948
Comments
Seeing this issue with k3s and the embedded etcd as well. k3s with an embedded etcd does work with I noticed a pull request to upgrade locksmith to etcd3 link, maybe that is the issue? ImpactNot able to use etcd based locksmith reboots with k3s Environment and steps to reproduce
Edit:Manually passing endpoints instead of using the defaults worked a little more: locksmithctl --etcd-cafile="/var/lib/rancher/k3s/server/tls/etcd/server-ca.crt" --etcd-certfile="/var/lib/rancher/k3s/server/tls/etcd/server-client.crt" --etcd-keyfile="/var/lib/rancher/k3s/server/tls/etcd/server-client.key" --endpoint https://127.0.0.1:2379,https://10.10.1.41:2379,https://10.10.1.41:2380 status
Error initializing etcd client: creating etcd lock client: net/http: HTTP/1.x transport connection broken: malformed HTTP response "\x00\x00\x06\x04\x00\x00\x00\x00\x00\x00\x05\x00\x00@\x00" Also tried the peer files, and those understandably didn't work. Expected behaviorlocksmith works with tls etcd in k3s. |
@bmbeverst can you configure |
Thanks @tormath1 I was unable to run So I did the reverse, configured
That is the same error that locksmith gave.
I grabbed the
Also in the startup log of k3s I see this line
And the latest k3s release shows it as running:
|
@bmbeverst that should be doable with:
but I kept getting the error, even if I see the flags being processed:
|
I see the same issue, the Any luck with the PR? |
@bmbeverst yes, I confirm it works correctly with the upgrade PR:
|
Since you are using k3s, which is Kubernetes, I think you could rather use FLUO https://github.com/flatcar/flatcar-linux-update-operator/ or kured https://github.com/kubereboot/kured/ instead of locksmith, or? |
The simplicity of locksmith is what I like, simple process to reboot nodes without any needing additional Kubernetes configuration. Ideally, Kubernetes should be able to tolerate a node rebooting without any issues. I didn't like kured because after creating a cluster it still needs to the update service to be deployed and configured in Kubernetes. I did not know about the Flatcar Linux Update Operator, but it also requires Kubernetes setup. Perhaps I am mistaken and this is the best path forward. I am trying to create a setup where I can fully automate the deployment of a multi-node k3s cluster with automatic updates. @tormath1 to test the PR, do I build locksmith with your PR and overwrite the binaries in the flatcar OS? |
In this case, I would recommend to investigate further with FLUO or Kured approach. Kured is only a daemon set that runs on each node (and compatible with Flatcar) and it can be easily deployed and it takes care of draining cleanly the nodes before reboot. For trying the PR you can build locally then upload the binary to your nodes in |
Thanks for the advice! Totally understand that the PR is not production ready. Really appreciate the help with this issue. |
Description
When
-etcd-cafile
is specified without a client cert/key, locksmith fails with the error:I've configured etcd with TLS using self-signed certificates but not TLS client authentication. locksmith seems to be looking for a certificate and key, even though these options are not applicable.
Impact
Error message is confusing, because it relates to an unrelated command line option.
Environment and steps to reproduce
a. locksmithctl -etcd-cafile=/etc/ssl/certs/ca-certificates.crt status
Error initializing etcd client: open : no such file or directory
Expected behavior
locksmith uses the specified CA to authenticate the server without client authentication.
Additional information
N/A.
The text was updated successfully, but these errors were encountered: