We already have a created LDAP Database with multiple groups and users.Now I want to add a new user and assign him to existing group
I have created a newuser.ldif file as follows
dn: uid=test,ou=people,dc=crmsldap,dc=agilent changetype: add objectClass: top objectClass: person objectClass: organizationalPerson objectClass: inetOrgPerson objectClass: posixAccount objectClass: shadowAccount cn: test sn: test uid: test userPassword: test uidNumber: 10000 gidNumber: 300 homeDirectory: /home/test
dn: cn=admin,ou=groups,dc=crmsldap,dc=agilent changetype: modify memberUid: test
When I run the script
/opt/symas/bin/ldapmodify -x -D "cn=Manager,dc=crmsldap,dc=agilent" -W -f newuser.ldif it gives an error as follows
ldapmodify: modify operation type is missing at line 21, entry "cn=admin,ou=groups,dc=crmsldap,dc=agilent"
Thanks Subbarao
dn: cn=admin,ou=groups,dc=crmsldap,dc=agilent changetype: modify memberUid: test
ldapmodify: modify operation type is missing at line 21, entry "cn=admin,ou= groups,dc=crmsldap,dc=agilent"
Reread ldapmodify(1). You are missing `replace: memberUid' or `add: ...' between line 2 and 3.
-JP
Hi,
Subbarao Karanam gudikal_karanam@yahoo.com writes:
We already have a created LDAP Database with multiple groups and users.Now I want to add a new user and assign him to existing group
I have created a newuser.ldif file as follows dn: uid=test,ou=people,dc=crmsldap,dc=agilent changetype: add
[...]
dn: cn=admin,ou=groups,dc=crmsldap,dc=agilent changetype: modify memberUid: test
When I run the script
/opt/symas/bin/ldapmodify -x -D "cn=Manager,dc=crmsldap,dc=agilent" -W -f newuser.ldif it gives an error as follows
ldapmodify: modify operation type is missing at line 21, entry "cn=admin,ou=groups,dc=crmsldap,dc= agilent"
Your ldif file is badly designed, man ldapmodfiy(5) has some good examples.
-Dieter
openldap-software@openldap.org