After etcd cluster upgraded from v3.4.34 -> v3.5.27, TotalDBSize has been increased and TotalDBSizeInUse remains stable.
#22012
Replies: 2 comments
-
Beta Was this translation helpful? Give feedback.
-
|
Q1 — Is this expected after upgrading to v3.5.x? Yes, this is expected and well-understood behavior. The v3.5 default change from With
With
Q2 — Has the The benchmarks that motivated the For clusters in the 8–10 GiB range you can safely switch back to This restores v3.4 behavior: the freelist is persisted, free pages are reused aggressively, and Q3 — Are there other changes that could contribute? Two v3.5 changes are worth knowing about but are secondary to the freelist change:
Defrag frequency concern You noted that frequent defragmentation is undesirable due to leader election risk. With |
Beta Was this translation helpful? Give feedback.

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
We recently upgraded our etcd clusters from
v3.4.34->v3.5.27and after the upgrade it has been observed that there has been significantly increase in etcd'stotalDBSizewhereastotalDBSizeInUseremains stable.The magnitude varies per cluster but the pattern is consistent across all of our etcd clusters.
Etcd v3.5.x has changed the default value of
--backend-bbolt-freelist-typefromarray(persisted to disk) tomap(in-memory). and because of this bolt-db is using hashmap to maintain the freelist, I suspect this to be the root cause of this issue.Questions:
v3.5.x?On the claim that "map freelist type has much better performance than array.", Has this been validated via perf testing for clusters running with a quota of
8–10 GiB? from this blog: https://www.cncf.io/blog/2019/05/09/performance-optimization-of-etcd-in-web-scale-data-scenario/ when this hashmap approach was introduced what I can understand that this hashmap based freelist was introduce for large-database scenarios. It is not clear that the performance benefit carries over to the small databases typical in most Kubernetes deployments.Is there any other feature/changes can cause this issue ?
Beta Was this translation helpful? Give feedback.
All reactions