Managed Kubernetes
Latest
How Can I Check The Current Disk Space Consumption By ETCD Database?
Problem
How can I check how much disk space is consumed by the ETCD database on the kubernetes cluster node?
Environment
Platform9 Managed Kubernetes - All Versions
ETCD
Answer
The current ETCD Database size can be checked using the command mentioned below.
The value under the
DB SIZEcolumn indicates the size of the ETCD database for the particular cluster node.
# ETCDCTL_API=3 /opt/pf9/pf9-kube/bin/etcdctl endpoint status --cluster --write-out=table --endpoints=http://127.0.0.1:2379 --cacert="/etc/pf9/kube.d/certs/etcdctl/etcd/ca.crt" --cert="/etc/pf9/kube.d/certs/etcdctl/etcd/request.crt" --key="/etc/pf9/kube.d/certs/etcdctl/etcd/request.key"
+-----------------------------+------------------+---------+---------+-----------+------------+-----------+------------+--------------------+--------+
| ENDPOINT | ID | VERSION | DB SIZE | IS LEADER | IS LEARNER | RAFT TERM | RAFT INDEX | RAFT APPLIED INDEX | ERRORS |
+-----------------------------+------------------+---------+---------+-----------+------------+-----------+------------+--------------------+--------+
| https://10.128.144.8:4001 | 767cdb8760094d16 | 3.4.18 | 17 MB | true | false | 220 | 25747862 | 25747862 | |
| https://10.128.145.228:4001 | 9ace043310f70c08 | 3.4.18 | 17 MB | false | false | 220 | 25747862 | 25747862 | |
The other command mentioned below provides the actual on disk size of the ETCD DB from Operating System Perspective. It can be considered as the way to confirm if the value mentioned under the
DB SIZEcolumn is correct or not.
# du -sch /var/opt/pf9/kube/etcd/data/member/snap/db
17M /var/opt/pf9/kube/etcd/data/member/snap/db
17M total
Additional Information
For additional information please refer Built-in ETCD snapshot.
Last updated on
Was this page helpful?
Frequently Asked Questions
Solutions
How Tos
Internal Only
Templates
Powered by
