Project

General

Profile

Actions

Bug #17476

closed

Bug #17421: Add log about node group update failure because of inconsistency

error about group consistency at upgrade from Rudder 6.0 to 6.1

Added by Nicolas CHARLES over 4 years ago. Updated over 4 years ago.

Status:
Released
Priority:
N/A
Category:
Web - Compliance & node report
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
Checked
Regression:

Description

parent ticket introduce logs, so that we can know what's going one


Files

clipboard-202006022046-pxzwz.png (12.7 KB) clipboard-202006022046-pxzwz.png François ARMAND, 2020-06-02 20:46

Related issues 1 (0 open1 closed)

Related to Rudder - User story #16347: Group propertiesReleasedNicolas CHARLESActions
Actions #1

Updated by Nicolas CHARLES over 4 years ago

could not reproduce
rejecting, will reopen if it still happen

Actions #2

Updated by Nicolas CHARLES over 4 years ago

  • Status changed from New to Rejected
Actions #3

Updated by Nicolas CHARLES over 4 years ago

  • Status changed from Rejected to New
  • Target version changed from 6.1.0~rc1 to 6.1.0~rc2

it still happens

[2020-05-28 09:54:19+0200] ERROR scheduled.job - Error when updating dynamic group 'all-nodes-with-cfengine-agent' <- Error when saving update for dynamic group 'All classic Nodes' (all-nodes-with-cfengine-agent) <- Consistancy: The group configuration changed compared to the reference group you want to change the node list for. Aborting to preserve consistency 

Actions #4

Updated by Nicolas CHARLES over 4 years ago

log in parent ticket doesn't work
when making it work, it says

Inconsistency when modifying node lists for nodeGroup All classic Nodes managed by root policy server: previous content was NodeGroup(NodeGroupId(hasPolicyServer-root),All classic Nodes managed by root policy server,All classic Nodes known by Rudder directly connected to the root server. This group exists only as internal purpose and should not be used to configure nodes.,List(),Some({ returnType:'NodeAndPolicyServerReturnType' with 'And' criteria [node.policyServerId eq root ; node.agentName eq cfengine] }),true,Set(NodeId(e8546e25-e5a7-4f82-bc51-eca5e568413c), NodeId(root)),true,true), new is NodeGroup(NodeGroupId(hasPolicyServer-root),All classic Nodes managed by root policy server,All classic Nodes known by Rudder directly connected to the root server. This group exists only as internal purpose and should not be used to configure nodes.,List(),Some({ returnType:'NodeAndPolicyServerReturnType' with 'And' criteria [node.policyServerId eq root ; node.agentName eq cfengine] }),true,Set(NodeId(e8546e25-e5a7-4f82-bc51-eca5e568413c), NodeId(root)),true,false) - only the node list should change

difference is in the last value: true vs false for isSystem

surprisingly, this is random

Actions #5

Updated by Nicolas CHARLES over 4 years ago

i don't understand how the status can differ

Actions #6

Updated by François ARMAND over 4 years ago

I see - the field that change is the last boolean, which is isSystem (see code). This one has a default value, so somewhere we are saving a system group without specifying it. It's a good idea to have that protection in place.

Default parameters are evil.

Actions #7

Updated by François ARMAND over 4 years ago

Hum, the only case where we use that default parameter seems to be for clone or group creation via ui/api - unlikely the problem for that group.

Actions #8

Updated by Vincent MEMBRÉ over 4 years ago

  • Target version changed from 6.1.0~rc2 to 6.1.0~rc3
Actions #9

Updated by François ARMAND over 4 years ago

  • Status changed from New to In progress
  • Assignee set to François ARMAND
Actions #10

Updated by François ARMAND over 4 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Nicolas CHARLES
  • Pull Request set to https://github.com/Normation/rudder/pull/3033
Actions #11

Updated by Nicolas CHARLES over 4 years ago

Actions #12

Updated by François ARMAND over 4 years ago

For posterity: we were forgetting to save the "isSystem" status, so corresponding attribute was deleted in ldap, and when read back, it was missing and defaulted to false (but only on one method, so once saved again it was their).

To reproduce:

- check that group "isSystem" is set to true in ldap or change its value to true otherwise,
- change some node agent from "community" to anything else,
- reload dyngroup

=> isSystem is now to false in entry.

Actions #13

Updated by François ARMAND over 4 years ago

  • Status changed from Pending technical review to Pending release
Actions #14

Updated by Vincent MEMBRÉ over 4 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 6.1.0~rc3 which was released today.

Actions #15

Updated by François ARMAND over 4 years ago

  • Fix check changed from To do to Checked
Actions

Also available in: Atom PDF