># pdbedit -v -a -m -u tardis
>ldapsam_modify_entry: Failed to add user dn=
uid=tardis$,ou=Machines,dc=amazing-internet,dc=net with: Object class 
>violation
 >         object class 'sambaSamAccount' requires attribute 'sambaSID'

        Did you create the machine account in /etc/passwd or in ldap
before using pdbedit ?
        

Extract from a python script I've done what am I doing in the ldap
before pdbedit -a -m.

def cre_ldif_machine(last_uidnumber):
        """ Cette fonction cr�e un fichier d'enregistrement ldap d'un
compte machine pour samba"
""
        sys.stdout = open('/etc/samba/bin/machine.ldif', 'w')
        print "dn: uid=%s,ou=pc,o=test,c=fr" %  sys.argv[1]
        print "objectclass: account"
        print "objectclass: posixaccount"
        print "objectclass: shadowaccount"
        print "uid:%s" % sys.argv[1]
        print "cn: Samba machine %s " % sys.argv[1]
        print "uidnumber: %s" %last_uidnumber
        print "gidnumber:504"
        print "homedirectory:/dev/null"
        print "loginshell:/bin/false"
        sys.stdout.close()


Are you sure to have the right object class and  attribute ?

        Jean-Marc

--
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba

Reply via email to