Project

General

Profile

Actions

Bug #14392

closed

If a rule targets too many groups, policy generation fails

Bug #14392: If a rule targets too many groups, policy generation fails

Added by Nicolas CHARLES almost 7 years ago. Updated over 6 years ago.

Status:
Released
Priority:
N/A
Category:
Performance and scalability
Target version:
Severity:
Major - prevents use of part of Rudder | no simple workaround
UX impact:
User visibility:
Infrequent - complex configurations | third party integrations
Effort required:
Very Small
Priority:
69
Name check:
Fix check:
Regression:

Description

With a very very large list of groups in a rules, the historization (part of policy generation) fails because we have a pkey constraint on table rulesgroupjoin (rules id + serialization of groups of rules)
However, this pk creates a btree, that cannot index long text - error is

ERROR:  index row size 3528 exceeds maximum 2712 for index "rulesgroupjoin_pkey" 
ASTUCE : Values larger than 1/3 of a buffer page cannot be indexed.
Consider a function index of an MD5 hash of the value, or use full text indexing.

dropping the pkey solves the issue

alter table rulesgroupjoin drop constraint rulesgroupjoin_pkey;

recreating an index is still necessary for correct perf of historization though:

CREATE INDEX rule_id_group on rulesgroupjoin (rulePkeyId);

Subtasks 1 (0 open1 closed)

Bug #14414: Migration script for 14392 about a rule targetting to many groupsReleasedNicolas CHARLESActions

Updated by Alexis Mousset almost 7 years ago Actions #1

  • Subject changed from if rules uses too numerous, policy generation fails because historisation fails to If rules uses too numerous, policy generation fails because historisation fails

Updated by Alexis Mousset almost 7 years ago Actions #2

  • Description updated (diff)

Updated by Nicolas CHARLES almost 7 years ago Actions #3

  • Subject changed from If rules uses too numerous, policy generation fails because historisation fails to If rules uses too much groups, policy generation fails because historisation fails

Updated by François ARMAND almost 7 years ago Actions #4

  • Target version changed from 4.1.20 to 4.1.21

Updated by François ARMAND almost 7 years ago Actions #6

  • Assignee set to Nicolas CHARLES

Updated by Nicolas CHARLES almost 7 years ago Actions #7

  • Status changed from New to In progress

Updated by Nicolas CHARLES almost 7 years ago Actions #8

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

Updated by François ARMAND almost 7 years ago Actions #9

  • Subject changed from If rules uses too much groups, policy generation fails because historisation fails to If rules uses too many groups, policy generation fails
  • Description updated (diff)

Updated by Nicolas CHARLES almost 7 years ago Actions #10

  • Status changed from Pending technical review to Pending release

Updated by François ARMAND over 6 years ago Actions #11

  • Subject changed from If rules uses too many groups, policy generation fails to If a rule uses too many groups, policy generation fails

Updated by Vincent MEMBRÉ over 6 years ago Actions #12

  • Subject changed from If a rule uses too many groups, policy generation fails to If a rule targets too many groups, policy generation fails
  • Priority changed from 70 to 69

Updated by Vincent MEMBRÉ over 6 years ago Actions #13

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.1.21, 4.3.11 and 5.0.9 which were released today.

Actions

Also available in: PDF Atom