Bug 471642 - Stop nscd when caching is disabled by authconfig
Stop nscd when caching is disabled by authconfig
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: authconfig (Show other bugs)
5.3
All Linux
medium Severity medium
: rc
: ---
Assigned To: Tomas Mraz
BaseOS QE
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-11-14 14:46 EST by Suzanne Hillman
Modified: 2013-04-12 15:57 EDT (History)
4 users (show)

See Also:
Fixed In Version: authconfig-5.3.21-6.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-05-14 03:35:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Suzanne Hillman 2008-11-14 14:46:23 EST
Description of problem:
If changes are made in authentication methods in system-config-authentication, and caching is enabled, please restart the caching server! Otherwise, losing a network connection makes the machine _VERY VERY UNHAPPY_. This is problematic if one happens to be on a laptop.

Version-Release number of selected component (if applicable):
authconfig-5.3.21-4.el5

How reproducible:
Always

Steps to Reproduce:
1. Setup machine via authconfig to use LDAP for auth and user information, and choose the cache user information option.
2. Let it talk to the LDAP server and such. Perhaps, boot with this setup.
3. Use authconfig to disable the LDAP auth and user information, then remove network connection.
  
Actual results:
Lots of major delays for _EVERYTHING_ the system tries to do.

Expected results:
No delays; it should not be trying to use LDAP anymore.

Additional info:
Comment 1 Tomas Mraz 2008-11-18 04:55:58 EST
Jakub, shouldn't nscd reload the nsswitch config file automatically?
Comment 2 Tomas Mraz 2008-11-20 12:24:51 EST
Apparently does not.
Comment 3 Tomas Mraz 2008-11-27 05:15:13 EST
Actually I cannot exactly reproduce your problem. If I have caching enabled in the UI the nscd is always restarted when authconfig settings are saved.

The only problem I see is if I disable caching in the UI it will not stop the nscd on save (it will just chkconfig it off) and then nscd is not stopped any more.

So during your testing do you see caching enabled in the ui?
Comment 4 Suzanne Hillman 2008-12-01 14:48:13 EST
That's very confusing. 

No, I was not turning it off, just ldap and kerberos settings. The reason I thought it was the caching is because restarting nscd fixed the problems I was seeing with the machine not actually stopping trying to talk to the LDAP server.
Comment 10 Petr Šplíchal 2009-05-05 13:36:04 EDT
I checked the behaviour of the fixed package and can confirm that
nscd is restarted upon any change of ldap service:

# authconfig --update --enableldap
Stopping nscd: [  OK  ]
Starting nscd: [  OK  ]

# authconfig --update --disableldap
Stopping nscd: [  OK  ]
Starting nscd: [  OK  ]

The same can be observed when enabling/disabling ldap through GUI.
The new version of authconfig correctly stops the nscd daemon when
caching is being disabled:

authconfig-5.3.21-5.el5
# authconfig --update --disablecache
# service nscd status
nscd (pid 6277) is running...

authconfig-5.3.21-6.el5
# authconfig --update --disablecache
Stopping nscd: [  OK  ]
# service nscd status
nscd is stopped

But does that really fix the issue mentioned in bug summary &
description?
Comment 11 Petr Šplíchal 2009-05-05 13:38:32 EDT
Sorry, forgot to mention that nscd restarting works the same
with both the old and the new package. There seems to be no
difference.
Comment 12 Tomas Mraz 2009-05-05 15:18:39 EDT
That's really questionable. But the bug with not stopping nscd with the cache disabled was there and it was fixed and I do not see other cases where authconfig would not restart nscd if it was necessary.
Comment 13 Petr Šplíchal 2009-05-06 03:37:08 EDT
In that case, I suggest to change the bug summary to: "stop nscd
service when caching is disabled by authconfig", as this is
(completely?) different issue and the original description is
confusing.

Suzanne, if you still experience the problem, please, file another
bug, as caching server is always restarted when a change is made
to ldap config.  The real cause of this issue must be in something
else.
Comment 14 Tomas Mraz 2009-05-06 03:58:34 EDT
Is it possible that following scenario happened?

nscd was started by other means (like manually 'service nscd start') but it was still disabled with chkconfig. Then old authconfig would not stop it when updating the configuration.
Comment 16 Suzanne Hillman 2009-05-06 10:43:20 EDT
It does sound like this bug will resolve my original problem, as it was when I was disabling caching via authconfig that it was not actually stopping it.
Comment 18 errata-xmlrpc 2009-05-14 03:35:33 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-0482.html

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