Bug #13845
closedAfter a node is deleted, a policy generation is started every 5 secondes
Description
I'm not exactly sure of what's going on here.
I installed a new Rudder server + one node, accepted the node, deleted the node. Then, every 5s, I see in the log:
[2018-11-16 12:54:03] TRACE com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - Cache check for node info gave 'false' (1 entry returned) [2018-11-16 12:54:03] DEBUG com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - NodeInfo cache is not up to date, last modification time: '2018-11-16T12:51:05.000+01:00', last cache update: '2018-11-16T12:51:05.000+01:00' => reseting cache with 1 entries [2018-11-16 12:54:03] TRACE com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - NodeInfo cache updated entries: [root] [2018-11-16 12:54:06] TRACE com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - Cache check for node info gave 'false' (1 entry returned) [2018-11-16 12:54:06] INFO scheduledJob - Update in node inventories main information detected: triggering a policy generation [2018-11-16 12:54:06] INFO com.normation.rudder.services.policies.PromiseGenerationServiceImpl - Start policy generation, checking updated rules [2018-11-16 12:54:06] TRACE com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - Cache check for node info gave 'false' (1 entry returned) [2018-11-16 12:54:06] DEBUG com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - NodeInfo cache is not up to date, last modification time: '2018-11-16T12:51:05.000+01:00', last cache update: '2018-11-16T12:51:05.000+01:00' => reseting cache with 1 entries [2018-11-16 12:54:06] TRACE com.normation.rudder.services.nodes.NodeInfoServiceCachedImpl - NodeInfo cache updated entries: [root] [2018-11-16 12:54:06] INFO policy.generation - No node configuration was updated, no promises to write [2018-11-16 12:54:06] INFO policy.generation - Timing summary: [2018-11-16 12:54:06] INFO policy.generation - Run pre-gen scripts hooks : 0 ms [2018-11-16 12:54:06] INFO policy.generation - Run pre-gen modules hooks : 0 ms [2018-11-16 12:54:06] INFO policy.generation - Fetch all information : 62 ms [2018-11-16 12:54:06] INFO policy.generation - Historize names : 10 ms [2018-11-16 12:54:06] INFO policy.generation - Build current rule values : 1 ms [2018-11-16 12:54:06] INFO policy.generation - Build target configuration : 4 ms [2018-11-16 12:54:06] INFO policy.generation - Write node configurations : 2 ms [2018-11-16 12:54:06] INFO policy.generation - Save expected reports : 0 ms [2018-11-16 12:54:06] INFO policy.generation - Run post generation hooks : 19 ms [2018-11-16 12:54:06] INFO policy.generation - Number of nodes updated : 0 [2018-11-16 12:54:06] INFO policy.generation - Policy generation completed in: 123 ms [2018-11-16 12:54:06] INFO policy.generation - Successful policy update '767' [started 2018-11-16 12:54:06 - ended 2018-11-16 12:54:06]
clear cache does not solve the problem. "Regenerate all policies" does not solve the problem.
Only tested on 4.3.7.
Updated by François ARMAND about 6 years ago
It's not in 4.1 but reprocubicle in debug in 4.3
Updated by François ARMAND about 6 years ago
- Status changed from New to In progress
Updated by François ARMAND about 6 years ago
The problem is due to the fact that deleted entries are never couting in the most recent entries (since the don't have nodeInfo anymore).
As soos as a new modification is done in an accepted node, the continuous regeneration ceases.
Updated by François ARMAND about 6 years ago
- Status changed from In progress to Pending technical review
- Assignee changed from François ARMAND to Vincent MEMBRÉ
- Pull Request set to https://github.com/Normation/rudder/pull/2091
Updated by François ARMAND about 6 years ago
OK, so the entryCSN attribute wasn't returned for deleted entries, so we weren't able to see that they were the culprit for most recent entries, and to filter them out for the next request.
Updated by François ARMAND about 6 years ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder|2591b6b6160e57115f6c96e3bd9ba2d93f1dcb44.
Updated by Vincent MEMBRÉ about 6 years ago
- Status changed from Pending release to Released