Bug 790334

Summary: tomcat-7.0.logrotate should specify "su root tomcat"
Product: [Fedora] Fedora Reporter: Martin Dengler <martin>
Component: tomcatAssignee: Ivan Afonichev <ivan.afonichev>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: akurtako, ivan.afonichev, java-sig-commits, jhutar, kdaniel
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: tomcat-7.0.26-1.fc17 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 876987 883806 (view as bug list) Environment:
Last Closed: 2012-12-19 08:27:59 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 876987, 883806    

Description Martin Dengler 2012-02-14 09:57:38 UTC
Description of problem:
Tomcat's logrotate.d file needs to set "su root tomcat" to suppress logrotate errors like:

error: skipping "/var/log/tomcat6/catalina.out" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.


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


How reproducible:

Always


Steps to Reproduce:

1. Install tomcat
2. Run /etc/cron.daily/logrotate

  
Actual results:


Expected results:

No errors.


Additional info:

Patch to fix is:

diff --git a/tomcat-7.0.logrotate b/tomcat-7.0.logrotate
index a87b4c0..926928a 100644
--- a/tomcat-7.0.logrotate
+++ b/tomcat-7.0.logrotate
@@ -4,5 +4,6 @@
     rotate 52
     compress
     missingok
+    su root tomcat
     create 0644 tomcat tomcat
 }

Comment 1 Ivan Afonichev 2012-02-14 10:23:31 UTC
Maybe it's better to set
tomcat:root as owner for /var/log/tomcat ?

Comment 2 Fedora Update System 2012-02-22 20:05:28 UTC
tomcat-7.0.26-1.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/tomcat-7.0.26-1.fc16

Comment 3 Fedora Update System 2012-02-22 20:05:45 UTC
tomcat-7.0.26-1.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/tomcat-7.0.26-1.fc17

Comment 4 Fedora Update System 2012-02-23 02:23:57 UTC
Package tomcat-7.0.26-1.fc16:
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing tomcat-7.0.26-1.fc16'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-2217/tomcat-7.0.26-1.fc16
then log in and leave karma (feedback).

Comment 5 Fedora Update System 2012-03-06 19:40:14 UTC
tomcat-7.0.26-1.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2012-03-16 21:22:07 UTC
tomcat-7.0.26-1.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 7 Jan Hutaƙ 2012-12-07 13:16:14 UTC
Hello,
I do see this again:

  tomcat-7.0.32-1.fc17.noarch

error log is:

error: skipping "/var/log/tomcat/catalina.out" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.

Comment 8 Fedora Update System 2012-12-07 13:28:00 UTC
tomcat-7.0.33-2.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/tomcat-7.0.33-2.fc17

Comment 9 Fedora Update System 2012-12-09 06:02:42 UTC
Package tomcat-7.0.33-2.fc17:
* should fix your issue,
* was pushed to the Fedora 17 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing tomcat-7.0.33-2.fc17'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-20025/tomcat-7.0.33-2.fc17
then log in and leave karma (feedback).

Comment 10 Fedora Update System 2012-12-09 21:39:40 UTC
tomcat-7.0.33-2.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/tomcat-7.0.33-2.fc18

Comment 11 Fedora Update System 2012-12-09 22:00:36 UTC
tomcat-7.0.33-1.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/tomcat-7.0.33-1.fc16

Comment 12 Fedora Update System 2012-12-19 08:28:04 UTC
tomcat-7.0.33-1.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 13 Fedora Update System 2012-12-19 08:42:07 UTC
tomcat-7.0.33-2.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 14 Fedora Update System 2013-01-11 23:42:05 UTC
tomcat-7.0.33-2.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.