Feature #27024
closedAudits cleanup
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1703496
Description of problem:
Satellite audits cleanup
Version-Release number of selected component (if applicable):
Satellite 6.4.2
How reproducible:
Always
Steps to Reproduce:
1.Some production Satellites have more than 5 million audit entries which degrades the performance of Satellite audit UI. Need an automatic cleanup mechanism to remove old audit entries.
Actual results:
Production Satellites accumulate large of Audit data which are not purged.
- time curl
k -u admin https://satellite.example.com/api/audits > audit:--:-- 0:00:17 --:--:-- 3534
Enter host password for user 'admin':
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 13950 0 13950 0 0 817 0 -
real 0m19.485s
user 0m0.047s
sys 0m0.066s
- head audit
{
"total": 5136427,
"subtotal": 5136427,
"page": 1,
"per_page": 30,
"search": null,
"sort": {
"by": null,
"order": null
},
Expected results:
Need an automated purge mechanism for audits.
Additional info:
Updated by Lukas Zapletal about 5 years ago
- Related to Feature #22158: Add a rake task for audits cleanup added
Updated by Marek Hulán about 5 years ago
The rake task is there, we should make it automatically executed, similar to how we clean up reports https://github.com/theforeman/foreman-packaging/blob/rpm/develop/packages/foreman/foreman/foreman.cron.d
Updated by Ondřej Ezr over 3 years ago
- Subject changed from Satellite audits cleanup to Audits cleanup
Updated by Ondřej Ezr over 3 years ago
I do not agree we should run the cleanup automatically. Audits should stay forever unless user say otherwise.
Unless we name this Activity log.
Updated by Dominik Matoulek almost 3 years ago
- Related to Feature #33623: Add cron to audits cleanup added
Updated by The Foreman Bot almost 3 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/8844 added
Updated by Dominik Matoulek almost 3 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset foreman|40818327a7d00e7735aad0af4830f6661dff177f.