... | ... | @@ -12,14 +12,14 @@ |
|
|
* Appendix B Multi-threaded Improvement
|
|
|
* Appendix C Design Variant
|
|
|
|
|
|
# Introduction
|
|
|
# Introduction
|
|
|
|
|
|
The primary issue is that assigned and declined lease statistics are not
|
|
|
accurate when multiple Kea servers are using "shared lease storage" without
|
|
|
Kea's HA protocol, as the servers are unaware of each other's contributions.
|
|
|
Herein, where the term HA appears it refers to Kea's HA protocol.
|
|
|
|
|
|
Other lease related statistics, such as relcaimed-declined and reclaimed, are
|
|
|
Other lease related statistics, such as reclaimed-declined and reclaimed, are
|
|
|
accurate on a per server basis as they represent running count of those
|
|
|
events since the last time that server reset its statistics.
|
|
|
|
... | ... | @@ -38,7 +38,7 @@ The first task then, is to determine how to achieve accurate numbers. In |
|
|
the following sections a number of approaches will be described and then
|
|
|
considerations for each approach examined.
|
|
|
|
|
|
## 1. Approaches to Achieving Accurate Data
|
|
|
## 1. Approaches to Achieving Accurate Data
|
|
|
|
|
|
### 1.1 Aggregate individual Kea server contributions
|
|
|
|
... | ... | @@ -450,7 +450,7 @@ must come from the !StatsMgr local values until such time as subnet |
|
|
configuration is supported in the DB or the value is explicitly propagated
|
|
|
to common storage.
|
|
|
|
|
|
## Appendix A SQL for Tables and Triggers
|
|
|
## Appendix A SQL for Tables and Triggers
|
|
|
|
|
|
The SQL to create the V4 table and trigger are shown below for both MySQL
|
|
|
and Postgresql follow.
|
... | ... | @@ -582,7 +582,7 @@ AFTER INSERT ON lease6 |
|
|
Note that update and delete triggers were also written and tested for
|
|
|
functionality but not timing, and were omitted for brevity.
|
|
|
|
|
|
## Appendix B Multi-threaded Improvement
|
|
|
## Appendix B Multi-threaded Improvement
|
|
|
|
|
|
A possible improvement for post 1.4 would be to offload the work of statistics
|
|
|
fetching to a separate thread in Kea servers. That would require the following:
|
... | ... | @@ -606,7 +606,7 @@ could have wide spread use. This would allow Kea servers to rather seamlessly |
|
|
respond to statistics requests without hampering their ability to provide DHCP
|
|
|
service.
|
|
|
|
|
|
## Appendix C Design Variant
|
|
|
## Appendix C Design Variant
|
|
|
|
|
|
Should the use of triggers be ruled out, the design detailed above could be
|
|
|
based upon recalculating statistics on demand with a few minor alterations:
|
... | ... | |