[Samba] smbpasswd problem with LDAP

Tom Palmaers tompee at ba.be
Mon Nov 25 16:06:01 GMT 2002


Hello,

I have installed / configured samba-ldap (compiled SAMBA_2_2 from CVS)

Whe i try to change the password for the root user, there is no problem.
If i try to change the password of an ordinary user, i get the
error: 

nas:~# smbpasswd -U william
New SMB password:
Retype new SMB password:
No user to modify!
Password changed for user william.
Failed to modify entry for user william.
Failed to modify password entry for user william

Ok, so i ran it with debugging on:

-- CUT --
load_unix_unicode_map: ISO8859-1 (init_done=0, override=0)
load_unicode_map: loading unicode map for codepage ISO8859-1.
New SMB password:
Retype new SMB password:
ldap_open_connection: starting...
Initializing connection to localhost on port 389
ldap_open_connection: connection opened
ldap_connect_system: Binding to ldap server as
"cn=root,ou=hasselt.be,o=hasselt,c=be"
ldap_connect_system: succesful connection to the LDAP server
ldap_search_one_user: searching
for:[(&(cn=william)(objectclass=sambaAccount))]
get_single_attribute: [uid] = [william]
Entry found for user: william
-- CUT -- 

Here we see that the correct user was found...

But then:

-- CUT --
get_single_attribute: [pwdLastSet] = [1]
get_single_attribute: [logonTime] = [0]
get_single_attribute: [logoffTime] = [0]
get_single_attribute: [kickoffTime] = [0]
get_single_attribute: [pwdCanChange] = [0]
get_single_attribute: [pwdMustChange] = [0]
get_single_attribute: [cn] = [william]
get_single_attribute: [homeDrive] = [<does not exist>]
homeDrive fell back to 
get_single_attribute: [smbHome] = [<does not exist>]
Home server: NAS
smbHome fell back to \\NAS\william
get_single_attribute: [scriptPath] = [<does not exist>]
scriptPath fell back to 
get_single_attribute: [profilePath] = [<does not exist>]
Home server: NAS
profilePath fell back to \\NAS\william\profile
get_single_attribute: [description] = [<does not exist>]
get_single_attribute: [userWorkstations] = [<does not exist>]
get_single_attribute: [rid] = [500]
get_single_attribute: [primaryGroupID] = [512]
init_sam_from_ldap: User [william] does not ave a uid!
ldap_open_connection: starting...
Initializing connection to localhost on port 389
ldap_open_connection: connection opened
ldap_connect_system: Binding to ldap server as
"cn=root,ou=hasselt.be,o=hasselt,c=be"
ldap_connect_system: succesful connection to the LDAP server
ldap_search_one_user: searching for:[(&(cn=)(objectclass=sambaAccount))]
No user to modify!
Password changed for user william.
Failed to modify entry for user william.
Failed to modify password entry for user william
-- CUT --

Here we all notice that it connect's again to the ldap and then searches
for [(&(cn=)(objectclass=sambaAccount))].

cn= does not exist and thus return no users. Why doesn't smbpasswd put
cn=william in there ???

Does anyone know a solution to this problem ???

Greetings,

---

Tom Palmaers



More information about the samba mailing list