TWSD-606: When removing a key: Automatically unlink any servers that are using this key
Review Request #800 — Created April 16, 2025 and updated — Latest diff uploaded
| Information | |
|---|---|
| wli | |
| AVX2 | |
| rel_avx_2_7_4 | |
| TWSD-606 | |
| Reviewers | |
| jasonchang, timlai | |
Background:
AVX uses chrony as NTP client. Chrony has 2 config files, chrony.conf and chrony.keys
chrony.conf: contains a list of NTP servers and options(like iburst, nts, key) for each server.
chrony.keys: contains a list of pre-shared keys with following format: key_id : key_value.
The relationship between server and key is configured in chrony.conf, It could be N to 1. ( N >= 0)
The key itself is saved in chrony.keys.
TODO:
We need make a decision how our software should behave one we delete a key from chrony.keys.
Approach 1
When removing a key: Do nothing. This follows the default behavior of the chrony software. Customers will need to manually unlink any servers that are using this key.
For example, if the customer deletes a key with key_id = 1 and they have the following configuration:
ntp server 192.168.1.10 iburst 1
ntp server 10.1.1.2 iburst 1
They will need to manually remove the key from both servers using the ntp server CLI command.Approach 2
When removing a key: Automatically unlink any servers that are using this key.
For example, if the customer deletes a key with key_id = 1 and they have:
ntp server 192.168.1.10 iburst 1
ntp server 10.1.1.2 iburst 1
They don’t need to take any action. The key will be automatically unlinked from both servers.
