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.
I'm not sure why, but the PID file was mislabeled. Correct label is rpcd_var_run_t. When I relabeled the PID file to var_run_t and restarted rpcbind I got the same AVCs as you. restorecon -Rv /var/run fixes it.
This request was resolved in Red Hat Enterprise Linux 7.0.
Contact your manager or support representative in case you have further questions about the request.
Description of problem: With fresh installation of RHEL7: # systemctl start nfs-lock.service Job failed. See system logs and 'systemctl status' for details. # tail /var/log/messages Mar 6 15:03:51 dhcp-25-173 rpc.statd[14837]: Version 1.2.5 starting Mar 6 15:03:51 dhcp-25-173 rpc.statd[14837]: Opening /var/run/rpc.statd.pid failed: Permission denied Mar 6 15:03:51 dhcp-25-173 systemd[1]: nfs-lock.service: control process exited, code=exited status=1 Mar 6 15:03:51 dhcp-25-173 systemd[1]: Unit nfs-lock.service entered failed state. # ausearch -ts recent -m avc ---- time->Tue Mar 6 15:03:51 2012 type=SYSCALL msg=audit(1331042631.422:264): arch=c000003e syscall=87 success=no exit=-13 a0=7fb13282d284 a1=7fff6f667bb8 a2=0 a3=7fff6f667be0 items=0 ppid=14836 pid=14837 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="rpc.statd" exe="/sbin/rpc.statd" subj=system_u:system_r:rpcd_t:s0 key=(null) type=AVC msg=audit(1331042631.422:264): avc: denied { unlink } for pid=14837 comm="rpc.statd" name="rpc.statd.pid" dev=tmpfs ino=32415 scontext=system_u:system_r:rpcd_t:s0 tcontext=unconfined_u:object_r:var_run_t:s0 tclass=file ---- time->Tue Mar 6 15:03:51 2012 type=SYSCALL msg=audit(1331042631.422:265): arch=c000003e syscall=2 success=no exit=-13 a0=7fb13282d284 a1=241 a2=1b6 a3=238 items=0 ppid=14836 pid=14837 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="rpc.statd" exe="/sbin/rpc.statd" subj=system_u:system_r:rpcd_t:s0 key=(null) type=AVC msg=audit(1331042631.422:265): avc: denied { write } for pid=14837 comm="rpc.statd" name="rpc.statd.pid" dev=tmpfs ino=32415 scontext=system_u:system_r:rpcd_t:s0 tcontext=unconfined_u:object_r:var_run_t:s0 tclass=file Version-Release number of selected component (if applicable): selinux-policy-3.10.0-56.el7.noarch How reproducible: 100% on a fresh installation Steps to Reproduce: 1. See description Actual results: rpc.statd cannot be started Expected results: rpc.statd can be started Additional info: # restorecon -RvvF /var/run/ restorecon reset /run/rpc.statd.pid context unconfined_u:object_r:var_run_t:s0->system_u:object_r:rpcd_var_run_t:s0 Looks like pid file is created with wrong context at first time.