[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Invalid syntax on ldapadd

I think posixAccount requires homeDirectory as well.   W/o that your syntax is invalid because the objectclass is being violated.

        ( nisSchema.2.0 NAME 'posixAccount' SUP top AUXILIARY
          DESC 'Abstraction of an account with POSIX attributes'
          MUST ( cn $ uid $ uidNumber $ gidNumber $ homeDirectory )
          MAY ( userPassword $ loginShell $ gecos $ description ) )

(source: RFC2307 : http://www.ietf.org/rfc/rfc2307.txt)

On Jan 29, 2008, at 3:24 PM, Vinh.CTR.Hoang@faa.gov wrote:

Hi, I'm very new ldap, and i'm wondering if you guys can help me with something.

I'm going over the some tutorials to setup ldap for authentication.  However, I can't seem to be able to add any users or groups.  
I'm Solaris 9, w/ openldap 2.3.35.  

my slapd.conf looks like:

database        bdb
suffix                "dc=caplan,dc=org"
rootdn                "cn=root,dc=caplan,dc=org"
rootpw                <PASSWORD>
directory        /usr/local/var/openldap-data
index                objecClass,uid,uidNumer,gidNumber eq
index                cn eq

the user i'm trying to add is:

dn: uid=ldapauth,dc=caplan,dc=org
objectclass: account
objectclass: posixAccount
objectclass: top
cn: ldapauth
uid: ldapauth
uidNumber: 100
gidNumber: 100

I have no trailling spaces.

my add commands is :
ldapadd -D "cn=root,dc=caplan,dc=org" -f <File>

no matter what i do i get "Invalid syntax"

Thanks in advance,

Chris G. Sellers, MLS      Lead Internet Engineer
National Institute for Technology & Liberal Education
535 West William Street, Ann Arbor, Michigan  48103
chris.sellers@nitle.org         734.661.2318