Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
This is a generic gluster-SELinux BZ which can be used to update all the new AVC's seen in your component testing against the latest build: selinux-policy-3.7.19-278.el6
Version-Release number of selected component (if applicable):
selinux-policy-3.7.19-278.el6
How reproducible:
Steps to Reproduce:
1.
2.
3.
Actual results: AVC's seen while testing
Expected results: No AVC's should be reported
Not sure why
type=AVC msg=audit(1434837661.846:13065): avc: denied { getattr } for pid=9591 comm="ps" path="/dev/tty2" dev=devtmpfs ino=5644 scontext=system_u:system_r:logrotate_t:s0-s0:c0.c1023 tcontext=system_u:object_r:tty_device_t:s0 tclass=chr_file
is needed. What are you getting in permssive mode?
(In reply to Miroslav Grepl from comment #2)
> Not sure why
>
> type=AVC msg=audit(1434837661.846:13065): avc: denied { getattr } for
> pid=9591 comm="ps" path="/dev/tty2" dev=devtmpfs ino=5644
> scontext=system_u:system_r:logrotate_t:s0-s0:c0.c1023
> tcontext=system_u:object_r:tty_device_t:s0 tclass=chr_file
>
> is needed. What are you getting in permssive mode?
These AVC's were from permissive mode. I have cleared my systems for other tests and now I am on enforcing mode.
Found following logrotate configs:
* /etc/logrotate.d/glusterfs
* /etc/logrotate.d/glusterfs-georep
The AVC related to ps is most likely triggered by the second one.
I would say it's a leaked file descriptor, because the /etc/logrotate.d/glusterfs-georep file does not handle stderr:
... {
sharedscripts
rotate 52
missingok
compress
delaycompress
notifempty
postrotate
for pid in `ps -aef | grep glusterfs | egrep "\-\-aux-gfid-mount" | awk '{print $2}'`; do
/usr/bin/kill -HUP $pid > /dev/null 2>&1 || true
done
endscript
}
Comment 6krishnan parthasarathi
2015-06-23 13:02:09 UTC
Milos,
Which file descriptor is being leaked here? /etc/logrotate.d/glusterfs also redirects stderr to /dev/null. Why is that not triggering the same AVC errors?
Does this needs a fix in glusterfs?