Questions tagged [etcdctl]

32 questions
8
votes
1 answer

ETCD Cluster getting rpc error: code = DeadlineExceeded desc = context deadline exceeded

just looking for some clarification here I have a 2 node etcd cluster: master01=http://10.1.1.21:2379,master02=http://10.1.1.22:2379 all running fine. If I login to master01 and do the following: etcdctl --cluster=true endpoint health i get a…
tinashe.chipomho
  • 387
  • 2
  • 8
  • 17
4
votes
4 answers

Errors when using etcdctl on Kubernetes cluster: "certificates signed by unknown authority"

I have minikube running and I am trying to list the keys on my ETCD. I downloaded the latest etcdctl client from github: https://github.com/etcd-io/etcd/releases/download/v3.3.18/etcd-v3.3.18-linux-amd64.tar.gz I tried to run it with the…
E235
  • 11,560
  • 24
  • 91
  • 141
3
votes
1 answer

kubernetes etcdctl where is it?

Silly question. Just setup a 4 node kubernetes cluster (one master node). The etcd pod is running in the kube-system. But I can not find the etcdctl in regular path. # find / -name etcdctl…
TJS
  • 31
  • 2
2
votes
1 answer

Disable history in etcd key value store

Is there any way to disable the history saving in etcd? I am going to use etcd as KV for my app and I don't need history for the key values. When I search etcd, I couldn't find about disabling the history. I don't want to use the compacting feature…
Vijayakumar
  • 117
  • 2
  • 9
2
votes
1 answer

Getting ETCD Metrics from etcdctl

I am trying to get ETCD metrics like the number of ETCD keys and size as well as the number of requests made to ETCD through exec (ing) into a kubernetes pod (etcdctl) and am not sure what command to use for this. An alternative (such as cUrl) would…
Shrey Baid
  • 343
  • 1
  • 3
  • 10
1
vote
1 answer

How can I properly use etcd Roles to control write permission on specific etcd key?

I start my etcd cluster using Go etcd/clientv3 with following parameters: "--name", "etcd-cluster" "--data-dir", "/var/lib/etcd", "--wal-dir", "/var/lib", …
armaka
  • 191
  • 5
1
vote
1 answer

Etcdctl to GET key that contains bash invalid symbols

I cannot use Go nor Python etcd APIs to perform interaction with etcd. I need to query: env ETCDCTL_API=3 etcdctl --endpoints=server:2379 --cert ca.pem --key ca.key --cacert cacert.pem --command-timeout=60s get $(echo…
armaka
  • 191
  • 5
1
vote
1 answer

Etcdctl cuts JSON quotes after put command

I'm trying to change my whole json object using etcdctl: etcdctl put /var/dir "{"key1" : "value1", "key2": "value2"}" And after this idk how, but this json become invalid, quotes are cutted: etcdctl get /var/dir {key1 : value1, key2: value2} How…
dan k
  • 41
  • 6
1
vote
0 answers

How to call etcdctl txn from python?

I need to perform an ETCD transaction to check if key_a is of given revision, and if yes, then to delete the key, and put in a new key_b with value of value_b. I want to do that from python, and I am really struggling with the way etcdctl txn…
Petr
  • 486
  • 7
  • 19
1
vote
1 answer

etcdctl: unknown command "save" for "etcdctl"

I entered the etcd container: kubectl -n kube-system exec -it etcd-k8scp -- sh The I try to backup the container like explained in the K8s docs ETCDCTL_API=3 etcdctl --endpoints $ENDPOINT snapshot save snapshotdb I get this error: Error: unknown…
guettli
  • 25,042
  • 81
  • 346
  • 663
1
vote
1 answer

Best practice for "Watch key changes" in etcd v3

we want to use etcd with the "watch" function to change our "/etc/hosts" file. A node should change the value and the watch should then write the change in "/etc/hosts". Node1 Input: etcdctl put master-server "192.168.10.1…
1
vote
0 answers

ETCD warning The server needs to initialize the root user

I have a simple etcd server running and I am using this github project called etcd-keeper to visualize the data in the etcd. you can find the etcd-keeper project here: https://github.com/evildecay/etcdkeeper I have created the root using etcdctl and…
1
vote
0 answers

etcdctl snapshot status cannot get hush of bucket

I am learning k8s and had an exercise to backup etcd data, so I used the command: ETCDCTL_API=3 etcdctl snapshot save --endpoints localhost:2379 --cacert=/etc/kubernetes/pki/etcd/ca.crt --cert=/etc/kubernetes/pki/etcd/server.crt…
master o
  • 59
  • 7
1
vote
1 answer

How to get etcd cluster ID from script?

I am writing a script to document the etcd clusters I create. I want to retrieve the cluster ID and member IDs and write it to a report. I can get the member IDs easily, using etcdctl member list. $ etcdctl member list 7a37a8973f10a944, started,…
dayuloli
  • 16,205
  • 16
  • 71
  • 126
0
votes
0 answers

Listing etcd prefixes at a specific level

I need to analyze a very large etcd key value database that I have no previous knowledge of or schema documentation. Using etcdctl I would just want to list top-level keys so I can start mind-mapping the structure. So lets say my etcd store…
Rino Bino
  • 366
  • 3
  • 15
1
2 3