Setting Up CIFS Server (Samba) In an LDAP Environment

Setting Up CIFS Server (Samba) in an LDAP Environment
13
Save your ldap credentials for the user that will be modifying the ldap directory for CIFS
Server:
smbpasswd -w <Directory Manager password>
Adding your CIFS Server users to the LDAP directory
NOW populate your netscape directory with your CIFS Server users:
If you already have an smbpasswd file, you can import this into your ldap directory as follows:
cat /var/opt/samba/private/smbpasswd |
/opt/samba/LDAP/import_smbpasswd.pl
Otherwise, you can add users individually in the following manner:
/opt/samba/LDAP/smbldap-tools/smbldap-useradd.pl S w <ldap passwd> -a
username
verify that this step worked:
./smbldap-usershow.pl S w <directory manager passwd> username
For instance to look up a user named ‘ddmc’ that was previously added:
# ./smbldap-usershow.pl -S -w expert88 ddmc
dn: uid=ddmc,ou=People,dc=alf,dc=cpqcorp,dc=net
objectClass: top
objectClass: account
objectClass: posixAccount
objectClass: sambaAccount
cn: ddmc
uid: ddmc
uidNumber: 1000
gidNumber: 100
homeDirectory: /home/ddmc
loginShell: /usr/bin/sh
gecos: System User added by samba
description: System User added by samba
userPassword: {crypt}x
pwdLastSet: 0
logonTime: 0
logofftime: 2147483647
kickoffTime: 2147483647
pwdCanChange: 0
pwdMustChange: 2147483647
displayName: System User added by samba
acctFlags: [UX]
rid: 3000
primaryGroupID: 1201