-
Notifications
You must be signed in to change notification settings - Fork 302
UnitState.UnitHash can be nil #720
Comments
This kinda relates to #730 - can we canonicalise the representation of a unit so we can safely regenerate these hashes within the agent? |
@bcwaldon as far as I can tell this is not (no longer?) actually true. Consider the following with 0.8.2:
...
Note that the |
Yes, the description of the ticket is off a bit. Currently, the first reconciliation results in all unit files found in /var/run/fleet/units seeding the first "current state" calculation with nil hashes and inactive target states. A simple preload step on Agent startup to seed the Agent's cache of unit hashes and target states (inactive vs loaded) would solve the problem here. Side note - reading the unit files verbatim from /var/run/fleet/units obviously won't give us the actual loaded unit files. We need to ask systemd over dbus what the effective unit files are since there could be drop-ins in effect. Unfortunately, fleet does not have the power to rectify this situation as it would be dangerous to allow it to remove files outside of its workspace that it did not place initially. |
Agents attempt to bootstrap themselves on startup based on units that are already loaded locally. When this happens, it will not have a cached UnitHash for the UnitState.
The text was updated successfully, but these errors were encountered: