Bug 2103022 - [RFE] Improve archive clean up mechanism
Summary: [RFE] Improve archive clean up mechanism
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: insights-client
Version: 8.6
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: CSI Client Tools Bugs
QA Contact: Red Hat subscription-manager QE Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-01 08:29 UTC by Jan Senkyrik
Modified: 2023-07-25 08:55 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-07-25 08:55:48 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-126833 0 None None None 2022-07-01 08:41:48 UTC

Description Jan Senkyrik 2022-07-01 08:29:47 UTC
Description of problem:

Bug 2009773 had introduced a new clean up mechanism for leftover insights archives in /var/tmp directory:

~~~
Handle SIGTERM signal

Archive is created in a directory under /var/tmp with the same prefix "insights-archive-". 
Each time a new archive is created, it removes the previous one if it exists. 
Reducing the amount of directories created and stored at the same time.
~~~


It's great that we implemented this but it's not ideal. The leftover archives will be there until the next insights run (usually 24hrs). It would be better to handle the clean-up during or right after insights run fails (for whatever reason).

Comment 3 Alba Hita 2022-07-04 15:44:27 UTC
Hi Jan (@jsenkyri)
The archive will only remain in /tmp/insights-archive when insights-client is killed with a SIGKILL signal. 
Keeping the file due to a failure could help investigate the cause of the problem. 
If we remove the archive right before the insights-client is killed, there is no 
room for post-mortem analysis in the archive.

Comment 4 Jan Senkyrik 2022-07-05 07:22:58 UTC
Hi Alba,

Right, that makes perfect sense.

Thanks for the explanation.

Comment 6 Jan Senkyrik 2022-07-05 11:15:14 UTC
Customer agrees to close this RFE.


Note You need to log in before you can comment on or make changes to this bug.