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.
DescriptionWilliam Yardley
2014-10-30 21:01:03 UTC
Description of problem:
Restart of saslauthd (when running as non-root user) fails, because permission
[root@smtp02 ~]# grep DAEMON /etc/sysconfig/saslauthd
DAEMONOPTS="--user saslauth"
Version-Release number of selected component (if applicable):
2.1.23-15
How reproducible:
very
Steps to Reproduce:
1. Upgrade saslauthd
Actual results:
saslauthd fails with the error:
[root@smtp02 ~]# /etc/init.d/saslauthd start
Starting saslauthd: saslauthd[2850] :main : could not open pid lock file: /var/run/saslauthd/saslauthd.pid.lock
saslauthd[2850] :main : open: Permission denied
saslauthd[2850] :main : Check to make sure the directory exists and is
saslauthd[2850] :main : writeable by the user this process runs as.
[FAILED]
[root@smtp02 ~]# chown -R saslauth:saslauth /var/run/saslauthd/
Expected results:
saslauthd starts normally, e.g.,
[root@smtp02 ~]# /etc/init.d/saslauthd start
Starting saslauthd: [ OK ]
Additional info:
Confirmed here, both the problem and the fix.
I think the Priority or Severity fields should be set to some urgency, since breakage in saslauthd cascades to numerous other services that depend on it.
An update of cyrus-sasl was pushed out recently without a fix for this issue. As a result, the ownership of /var/run/saslauthd was reset from saslauth back to root, and saslauthd died when the %post script restarted it.
Is there any plan to fix this, or a recommended solution?
Presumably folks who haven't set
DAEMONOPTS=--user saslauth
in /etc/sysconfig/saslauthd
wouldn't be affected (IIRC, this may be the default?)
However, as it's a good practice to run as an unprivileged user, seems like there should be some way to have permissions on /var/run/saslauthd not get reset if it already exists (this is coming from the directory in the RPM itself). I don't know what the right fix would be off the top of my head, but hoping this is something that's possible to work around.
My best guess is the 2.1.23-15 update changed the owner of /var/run/saslauthd from saslauth to root, although the changelog doesn't mention such a change. Someone with VCS access could verify.
Ownership by the saslauth user seems reasonable: after all, it's listed as the 'Saslauthd user' in /etc/passwd. If folks really want to run saslauthd as root, saslauth ownership on that directory wouldn't cause problems.
Before the 2.1.23-15 update, default ownership might or might not have been by saslauth; again, someone with VCS access could tell. If it were, in any setup where /etc/sysconfig/saslauthd is untouched (most?), upgrade would have gone smoothly, since that file would have been updated. In our case, we changed an unrelated setting (MECH=ldap), so /etc/sysconfig/saslauthd, marked %config(noreplace) in the specfile, wasn't replaced.
Let me know if I can do any more forensics ;), and thanks for looking at this bug.
Thanks you for taking time to report this bug. This seems to be there for quite a long time. Hopefully we will put this into rhel-6.8.
Closing as duplicate of another bug which is covering another related issue.
*** This bug has been marked as a duplicate of bug 1188062 ***
Description of problem: Restart of saslauthd (when running as non-root user) fails, because permission [root@smtp02 ~]# grep DAEMON /etc/sysconfig/saslauthd DAEMONOPTS="--user saslauth" Version-Release number of selected component (if applicable): 2.1.23-15 How reproducible: very Steps to Reproduce: 1. Upgrade saslauthd Actual results: saslauthd fails with the error: [root@smtp02 ~]# /etc/init.d/saslauthd start Starting saslauthd: saslauthd[2850] :main : could not open pid lock file: /var/run/saslauthd/saslauthd.pid.lock saslauthd[2850] :main : open: Permission denied saslauthd[2850] :main : Check to make sure the directory exists and is saslauthd[2850] :main : writeable by the user this process runs as. [FAILED] [root@smtp02 ~]# chown -R saslauth:saslauth /var/run/saslauthd/ Expected results: saslauthd starts normally, e.g., [root@smtp02 ~]# /etc/init.d/saslauthd start Starting saslauthd: [ OK ] Additional info: