Created
March 21, 2022 21:32
-
-
Save flrichar/c4dcb0d7a034dd03c9d9e2483fa5312c to your computer and use it in GitHub Desktop.
count all objects in etcd from RKE
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| docker exec etcd etcdctl get /registry --prefix=true --keys-only | grep -v ^$ | awk -F'/' '{ if ($3 ~ /cattle.io/) {h[$3"/"$4]++} else { h[$3]++ }} END { for(k in h) print h[k], k }' | sort -n > etcd-count-objecttype.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment