One of my older production servers still runs Debian/stable. Usually the slow-cycle updates are great but not with the wierd things I’ve been running on it. Something along the lines of Bug#399849 over at Debian solved and repeated very easily. File permissions and ownership in my /etc got screwed around by asterisk and possibly a Debian update, causing this bug.
To re-create, on a system using nsswitch with LDAP (users & groups):
# chmod 600 /etc/libnss-ldap.conf
Log in with an LDAP user and perform any action that will query LDAP (ls, ps, etc.):
~$ ls -l ls: ldap-nss.c:1374: do_init: Assertion `cfg->ldc_uris[__session.ls_current_uri] != ((void *)0)' failed. Aborted
Solution: make the file readable
# chmod a+r /etc/libnss-ldap.conf
Before the fix shell logins still worked, however since the UID was not in the passwd file and not queryable by LDAP many functions and applications refused to operate for security reasons. Everything seems to be working with the permissions change with no side-effects.
{ 1 comment… read it below or add one }
Thanks for publishing this info. I just had a machine with the same problem after updating to Debian Etch.