Bug 1103676 - ovirt-engine should not store long term files in "/var/tmp/ovirt-engine/": tmpwatch will remove that directory after 30 days [NEEDINFO]
Summary: ovirt-engine should not store long term files in "/var/tmp/ovirt-engine/": tm...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-setup
Version: 3.3.0
Hardware: All
OS: Linux
urgent
urgent
Target Milestone: ---
: 3.5.0
Assignee: Sandro Bonazzola
QA Contact: Jiri Belka
URL:
Whiteboard: integration
Depends On:
Blocks: 1119178 rhev3.5beta 1156165
TreeView+ depends on / blocked
 
Reported: 2014-06-02 10:41 UTC by Anil Vettathu
Modified: 2019-05-20 11:13 UTC (History)
21 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Previously, the Red Hat Enterprise Virtualization Manager stored files in /var/tmp/ovirt-engine, and tmpwatch deleted those files on a monthly basis. This caused a failure in the Manager. Now, files are stored in /var/lib and tmpwatch does not delete them.
Clone Of:
: 1119178 (view as bug list)
Environment:
Last Closed: 2015-02-11 18:02:48 UTC
oVirt Team: ---
Target Upstream Version:
Embargoed:
ylavi: needinfo? (avettath)


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 901573 0 None None None Never
Red Hat Product Errata RHSA-2015:0158 0 normal SHIPPED_LIVE Important: Red Hat Enterprise Virtualization Manager 3.5.0 2015-02-11 22:38:50 UTC
oVirt gerrit 29708 0 None None None Never
oVirt gerrit 29752 0 None None None Never
oVirt gerrit 29754 0 None None None Never

Description Anil Vettathu 2014-06-02 10:41:01 UTC
Description of problem:

/etc/cron.daily/tmpwatch had deleted files which are not modified for more than 30 days from "/var/tmp/ovirt-engine/". This created issue with ovirt-engine (RHEV) service and it stopped functioning. Thus affecting customer's production environment

Version-Release number of selected component (if applicable):

tmpwatch-2.9.16-4.el6.x86_64

How reproducible:

Always.

Steps to Reproduce:
1. start ovirt-engine service
2. Make sure tmpwatch daily cronjob is running (/etc/cron.daily/tmpwatch)



Actual results:
After 30 days, tmpwatch will delete files which are not modified from /var/tmp/ovirt-engine/

Expected results:
tmpwatch should exclude /var/tmp/ovirt-engine/ from its cleaning process.

Additional info:

Suggested the following workaround till the issue is resolved.

Modify ' /usr/sbin/tmpwatch "$flags" 30d /var/tmp ' to ' /usr/sbin/tmpwatch "$flags" -x /var/tmp/ovirt-engine 30d /var/tmp ' (this will exclude /var/tmp/ovirt-engine)

Comment 1 Miloslav Trmač 2014-06-03 16:05:47 UTC
Why is (In reply to Anil Vettathu from comment #0)
> After 30 days, tmpwatch will delete files which are not modified from
> /var/tmp/ovirt-engine/

No, it will delete files which are not _accessed_ for 30 days.  Why is ovirt-engine storing long-term data in there in the first place?  AFAICT it shouldn’t, contents of /var/tmp are explicitly expected to be deleted at unpredictable time per http://www.pathname.com/fhs/pub/fhs-2.3.html#PURPOSE50 .

Comment 2 Alon Bar-Lev 2014-06-04 07:00:46 UTC
I do not expect blind periodic delete /var/tmp, however it is easy enough to move this tmp to /var/lib/ovirt-engine/tmp.

You can now set ENGINE_TMP within /etc/ovirt-engine/engine.conf/30-tmpdir.conf:

 ENGINE_TMP="${ENGINE_VAR}/tmp"

Comment 3 Alon Bar-Lev 2014-06-04 07:09:12 UTC
Sandro,
When sending modification, please separate between the jboss tmp layout and the tmpdir, make the jboss layout reside at lib.
Thanks,

Comment 5 Alon Bar-Lev 2014-06-04 15:57:59 UTC
(In reply to Alon Bar-Lev from comment #2)
> I do not expect blind periodic delete /var/tmp, however it is easy enough to
> move this tmp to /var/lib/ovirt-engine/tmp.
> 
> You can now set ENGINE_TMP within
> /etc/ovirt-engine/engine.conf/30-tmpdir.conf:
> 
>  ENGINE_TMP="${ENGINE_VAR}/tmp"

Sorry... forgot the .d

/etc/ovirt-engine/engine.conf.d/30-tmpdir.conf:
---
ENGINE_TMP="${ENGINE_VAR}/tmp"
---

Comment 10 Yedidyah Bar David 2014-07-08 12:48:03 UTC
(In reply to Alon Bar-Lev from comment #3)
> Sandro,
> When sending modification, please separate between the jboss tmp layout and
> the tmpdir, make the jboss layout reside at lib.

Why not move all of ENGINE_TMP to lib? Is there anything that must stay at /var/tmp ?

Comment 11 Alon Bar-Lev 2014-07-08 14:04:38 UTC
(In reply to Yedidyah Bar David from comment #10)
> (In reply to Alon Bar-Lev from comment #3)
> > Sandro,
> > When sending modification, please separate between the jboss tmp layout and
> > the tmpdir, make the jboss layout reside at lib.
> 
> Why not move all of ENGINE_TMP to lib? Is there anything that must stay at
> /var/tmp ?

please leave the ENGINE_TMP within /var/tmp/ovirt-engine, it may have other uses, please have a different variable for the jboss layout.

Comment 12 Yedidyah Bar David 2014-07-09 11:49:51 UTC
http://gerrit.ovirt.org/29752 is for ovirt-reports.

Comment 15 Jiri Belka 2014-07-29 14:15:49 UTC
ok, looks for for engine (ovirt-engine-3.5.0-0.0.master.20140722232058.git8e1babc.el6.noarch) and reports (ovirt-engine-reports-3.5.0-0.5.el6.noarch.rpm).

Comment 19 errata-xmlrpc 2015-02-11 18:02:48 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2015-0158.html


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