Bug 476504 - smbldap-tools kills nscd
Summary: smbldap-tools kills nscd
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: smbldap-tools
Version: 9
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Paul Howarth
QA Contact: Fedora Extras Quality Assurance
URL: https://gna.org/bugs/?13098
Whiteboard:
: 465230 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-12-15 10:29 UTC by Marek Greško
Modified: 2009-05-09 04:13 UTC (History)
1 user (show)

Fixed In Version: 0.9.5-4.fc9
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-05-09 04:02:40 UTC


Attachments (Terms of Use)

Description Marek Greško 2008-12-15 10:29:26 UTC
Description of problem:
There is a race condition in smbldap-tools. It restarts nscd. If two instances are run, there is a possibility, that nscd will not start after stop.


Version-Release number of selected component (if applicable):
smbldap-tools-0.9.5-2.fc9.noarch


How reproducible:
Occasionally. On many parallel changes on ldap it is quiet often.

Steps to Reproduce:
1. Run nscd.
2. Do many parallel updates of users and groups in ldap.
3. Wait for nscd not to start.
  
Actual results:
smbldap-tools stops nscd.

Expected results:
nscd ramians running.

Additional info:
I think there is no reason for doing anything to nscd. The restart to nscd does not invalidate cache or anything else.

If there is a need to invalidate the cache, it should be done through
/usb/sbin/nscd -i passwd and /usr/sbin/nscd -i group.

Also I suspect that if I add 10000 users to a group by /usr/sbin/smbldap-tools -m u1,u2,u3,...,u10000 groupname than nscd is restarted 10000 times after adding every user.

Comment 1 Paul Howarth 2009-03-01 12:03:03 UTC
*** Bug 465230 has been marked as a duplicate of this bug. ***

Comment 2 Paul Howarth 2009-03-01 12:08:25 UTC
I'm of the opinion that smbldap-tools shouldn't do anything to nscd; the only possible benefit to doing it is to refresh the passwd/group database on the machine smbldap-tools is running on, but it doesn't help any other client of the LDAP server that might be running nscd. So I intend to patch out the references to nscd.

Anybody disagree?

Comment 3 Paul Howarth 2009-03-06 16:34:05 UTC
(In reply to comment #2)
> I'm of the opinion that smbldap-tools shouldn't do anything to nscd; the only
> possible benefit to doing it is to refresh the passwd/group database on the
> machine smbldap-tools is running on, but it doesn't help any other client of
> the LDAP server that might be running nscd. So I intend to patch out the
> references to nscd.
> 
> Anybody disagree?  

OK, I disagree with myself. I'm patching it to invalidate the passwd and group caches whenever it would have done a start, stop, or restart of nscd.

I have packages built with this patch that you can test here:

http://mirror.city-fan.org/ftp/contrib/yum-repo/fc9/x86_64/repoview/smbldap-tools.html

Comment 4 Fedora Update System 2009-04-14 09:08:45 UTC
smbldap-tools-0.9.5-4.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/smbldap-tools-0.9.5-4.fc10

Comment 5 Fedora Update System 2009-04-14 09:09:30 UTC
smbldap-tools-0.9.5-4.fc9 has been submitted as an update for Fedora 9.
http://admin.fedoraproject.org/updates/smbldap-tools-0.9.5-4.fc9

Comment 6 Fedora Update System 2009-04-14 15:56:02 UTC
smbldap-tools-0.9.5-4.fc9 has been pushed to the Fedora 9 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing-newkey update smbldap-tools'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F9/FEDORA-2009-3659

Comment 7 Marek Greško 2009-05-06 22:16:31 UTC
I confirm the bug is fixed. I have nscd running for 19 days now.

Comment 8 Paul Howarth 2009-05-07 08:07:49 UTC
Thanks; I'll get the update pushed to stable.

Comment 9 Fedora Update System 2009-05-09 04:02:35 UTC
smbldap-tools-0.9.5-4.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2009-05-09 04:13:16 UTC
smbldap-tools-0.9.5-4.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.


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