sw-collector: Iterate through history logs

The logrotate function causes the apt history to be split into
several parts at arbitrary points in time. If history.log only
is parsed then some package installation changes stored in
zipped backup history files might get lost.

Thus sw-collector now searches all backup history files until
a date older than the current event stored in the collector.db
database is found, so that no entries get overlooked.
This commit is contained in:
Andreas Steffen committed 2021-12-31 14:33:22 +01:00
1 parent 0b76ca13ab
commit 903c68e069
4 files changed
+142 -56

No files matched your search

@@ -23,17 +23,17 @@ INSERT INTO sw_identifiers (
INSERT INTO sw_events (
eid, sw_id, action
) VALUES (
2, 1, 2
3, 1, 2
);
INSERT INTO sw_events (
eid, sw_id, action
) VALUES (
2, 2, 2
3, 2, 2
);
INSERT INTO sw_events (
eid, sw_id, action
) VALUES (
2, 3, 2
3, 3, 2
);