how to use ldapadd


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers how to use ldapadd
# 1  
Old 02-15-2011
how to use ldapadd

We have netgroup in ldap in Sun java directory server, how can I add or remove a user to/from a netgroup via command line without using ldif file? I need to put this into a script.
Here is a sample netgroup, and I want to add user tonyz to it:
Code:
# ldapsearch  -h ldapserver.com -p 389 -b  "ou=netgroup,dc=ldapserver,dc=com" cn=SudoGrp_test        
version: 1
dn: cn=SudoGrp_test,ou=netgroup,dc=ldapserver,dc=com
nisNetgroupTriple: (,thomasw,)
cn: SudoGrp_test
description: test
description: Thomas Wu
objectClass: top
objectClass: nisNetgroup


Last edited by pludi; 02-15-2011 at 08:44 AM..
# 2  
Old 02-15-2011
Code:
man ldapadd

 
Login or Register to Ask a Question

Previous Thread | Next Thread

1 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

need script for smbldap-useradd/setquota/ldapadd

Hello guys, I am trying to add users to samba/ldap system, set their quota, set them a common password and add auto_home records for the new users User list file is in below format Firstname Lastname Username Command I run to add user is smbldap-useradd -a -m -N $Firstname -S... (0 Replies)
Discussion started by: upengan78
0 Replies
Login or Register to Ask a Question