Project

General

Custom queries

Profile

Actions

Bug #4480

closed

When restoring archive (full or groups) dynamic groups are created empty

Added by Vincent MEMBRÉ about 11 years ago. Updated almost 6 years ago.

Status:
Released
Priority:
1 (highest)
Category:
Web - Config management
Target version:
Severity:
Critical - prevents main use of Rudder | no workaround | data loss | security
UX impact:
User visibility:
Operational - other Techniques | Technique editor | Rudder settings
Effort required:
Large
Priority:
0
Name check:
Fix check:
Regression:

Description

When your restore an archive, dynamic groups are restored empty, meaning that Rules won't be generated on those empty groups.

Since dynamic group reload occurs only every 5 minutes, Rules won't be deployed until taht event occurs.

It can be launched manually within the webapp, in Administration -> Settings page or by using the api on the url /api/dyngroup/reload

When groups are restaured and automatic group reloading should be launched before deployment.


Subtasks 1 (0 open1 closed)

Bug #14771: Use of unitialized value error when restoring archiveReleasedNicolas CHARLESActions

Related issues 5 (4 open1 closed)

Related to Rudder - Bug #14758: Accepting a change request on dynamic group, make the group empty leads an invalid policy generation ReleasedNicolas CHARLESActions
Related to Change validation - Bug #14766: When accepting a change request on a group, it's node list should be computed before savingNewActions
Related to Rudder - Architecture #14767: When we accept nodes, dynamic group should be automatically updated at the end of the acceptation, in a synchronized wayNewActions
Related to Rudder - Architecture #7471: Techniques should be reloaded before importing an archiveNewActions
Related to Rudder - Bug #15183: Reload technique library when restoring an archiveNewActions
Actions #1

Updated by François ARMAND about 11 years ago

  • Status changed from New to 8

So, it's less trivial than initially thought:

- 1/ updating dynamic group is done asynchronously, so if we start it before starting promise generation, the result will certainly not be what we want (only partial update of groups ?)
- 2/ but if we issue a not asynchronous dynamic update, it may be long and make the import process even longer.

So, it seems that we want a way to start other things at the end of the dyngroup generation, something "on complete" (that does not exists for now).

Actions #2

Updated by Nicolas CHARLES about 11 years ago

I guess the import time is not that bad, compared to the alternative of having incomplete promises.
Plus, the time of computing groups is in seconds, isn't it ?

Actions #3

Updated by François ARMAND about 11 years ago

Yes, computing groups is quick. But you have to either wait for the next dynamic group generation (by default, 5 min if no luck), or trigger it by hand (need a second action). So it would be far better to have the trigger trigged automatically :)

Actions #6

Updated by Nicolas CHARLES about 11 years ago

Maybe we could:
- start a dyn update
- wait for x secondes
- deploy

what do you think of it ?

Actions #60

Updated by Nicolas CHARLES almost 6 years ago

it also happens when validating change request, but it's even worse as it does not trigger a dynamic group update - so it lasts much longer in an invalid state

Actions #62

Updated by Nicolas CHARLES almost 6 years ago

  • Target version changed from 4.1.20 to 5.0.10

Targeting to 5.0, as #14758 take care of the workaround in 4.1

when importing an archive, it should compute node list before saving. This should be synchronized, as others actions can happen at the same time (accept node, change request, etc), and this computation should block loading nodes list in policy generation

Actions #67

Updated by Vincent MEMBRÉ almost 6 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from Vincent MEMBRÉ to Nicolas CHARLES
  • Pull Request set to https://github.com/Normation/rudder/pull/2204
Actions #68

Updated by Vincent MEMBRÉ almost 6 years ago

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

Updated by Vincent MEMBRÉ almost 6 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.1.22, 4.3.12 and 5.0.10 which were released today.

Actions

Also available in: Atom PDF