Architecture #15864
open
Add an option to remove the backup of node policy at the end of policy generation
Added by Nicolas CHARLES over 4 years ago.
Updated 7 days ago.
Category:
Performance and scalability
Description
When we generate policies, we are deleting previous backup, moving previous policies to backup folder, and moving new policies to final position. This can be really long (if it's on a different mount point, it can take up to a 1/3 of the policy generation time, for instance with 10 000 nodes, it took 1200 seconds), but we need to move the previous policies out of the way to have unitary changes - ticket #16072 takes care of documenting that they should be on the same FS.
Ultimately, these backup are rarely used, so we could simply drop them async at the end of generation, so that we don't have to delete them during next policy generation, and save some disk space, time and IO - this could be done via a post generation hook
- remove the backup of previous policies at the end generation
curl -k -H "X-API-Token: xxx" -X POST 'https://.../rudder/api/latest/settings/rudder_remove_previous_policies' -d "value=true"
- Status changed from New to In progress
- Assignee set to Nicolas CHARLES
- Description updated (diff)
- Category deleted (
Performance and scalability)
- Target version deleted (
5.0.15)
- Name check deleted (
To do)
- Category set to Performance and scalability
- Target version set to 5.0.15
- 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/2561
- Related to Bug #16072: Improve documentation in rudder-web.properties about backup folder added
- Status changed from Pending technical review to In progress
it's a bit more complex than that - deleting rather than moving the old policies is not atomic, so can end up with broken policies on the node/relay if shared at the wrong time (the error windows is too large).
Note that having /var/rudder/backup on a different fs than /var/rudder/share result also in non atomic change (the move is a copy+delete)
- Subject changed from add an option to prevent backup of node policy at the end of policy generation to Add an option to remove the backup of node policy at the end of policy generation
- Description updated (diff)
- Target version changed from 5.0.15 to 5.0.16
- Target version changed from 5.0.16 to 5.0.17
- Target version changed from 5.0.17 to 5.0.18
- Tracker changed from Bug to Architecture
- Target version changed from 5.0.18 to 6.2.0~beta1
- Priority deleted (
0)
- Target version changed from 6.2.0~beta1 to 6.2.0~rc1
- Target version changed from 6.2.0~rc1 to 6.1.7
- Target version changed from 6.1.7 to 6.1.8
- Target version changed from 6.1.8 to 6.1.9
- Target version changed from 6.1.9 to 6.1.10
- Target version changed from 6.1.10 to 6.1.11
- Target version changed from 6.1.11 to 6.1.12
- Target version changed from 6.1.12 to 6.1.13
- Target version changed from 6.1.13 to 6.1.14
- Target version changed from 6.1.14 to 6.1.15
- Target version changed from 6.1.15 to 6.1.16
- Target version changed from 6.1.16 to 6.1.17
- Target version changed from 6.1.17 to 6.1.18
- Target version changed from 6.1.18 to 6.1.19
- Target version changed from 6.1.19 to 6.1.20
- Target version changed from 6.1.20 to 6.1.21
- Target version changed from 6.1.21 to old 6.1 issues to relocate
- Status changed from In progress to New
- Target version changed from old 6.1 issues to relocate to 8.0.0~alpha1
- Target version changed from 8.0.0~alpha1 to 8.0.0~beta1
- Target version changed from 8.0.0~beta1 to 8.1.0~alpha1
- Target version changed from 8.1.0~alpha1 to 8.1.0~beta1
- Target version changed from 8.1.0~beta1 to 8.1.0~beta2
- Target version changed from 8.1.0~beta2 to 8.1.0~beta3
Also available in: Atom
PDF