LDAP-UX Client Services B.04.15 Administrator's Guide
Command Arguments
The following describes arguments/options used in the above examples for the ldapugmod -t
passwd commands:
-PW Sets the user or group password attribute. If you specify -PW, you must
specify either the LDAP-UGCRED environment variable or the -PP option.
-A <attrval>
Specifies an attribute and value to be added to a user or group entry.
When working with multi-valued attributes, you can use the -A option
to add a new value for a multi-valued attribute, without removing already
existing values for that attributes.
-R <attrval>
Specifies an attribute and value to be removed from a user or group entry.
When working with multi-valued attributes, you can use the -R option
to remove a specified value for a multi-valued attributes.
-u <uidNumber>
Replaces the user's numeric id number.
-I <gecos> Replaces the GECOS fields for the user. Typically the GECOS argument
contains the following four fields which represent (in order):
• The user's full name
• The user's work location
• The user's work telephone number
• The user's home telephone number (often omitted)
Each field in the <gecos> argument must be separated by a comma.
<attr>=<value>
Allows modification of arbitrary LDAP attributes and values.
5.6.6 Modifying a Group
You can use ldapugmod tool to modify exiting groups in an LDAP directory server. This section
provides examples of using ldapugmod to modify group entry information.
The following command replaces the gidNumber value for the group entry, GroupA:
./ldapugmod -t group -g 2500 groupA
In the following example, a group entry contains multiple values of the description attribute.
It is as follows:
dn: cn=GroupB,ou=Group,dc=example,dc=com
cn: GroupB gidNumber: 350 MemberUid: tlee Description: Test Group
Description: A Group Entry
Run the following command to replace all instances of the description attribute with new
value “Group B Entry” for the GroupB entry:
./ldapugmod -t group GroupB "description=Group B Entry"
The result of the GroupB entry is as follows:
dn: cn=GroupB,ou=Group,dc=example,dc=com
cn: GroupB gidNumber: 350 MemberUid: tlee Description: Group B Entry
In the following example, a group entry in an LDAP directory server is as follows:
dn: cn=GroupC,ou=Group,dc=example,dc=com
cn: GroupC gidNumber: 500 MemberUid: alouie Description: A IT Group
Description: A Group Entry
Run the following command to add an instance of the description attribute and value to the
group entry, GroupC, without removing already existing values for that attributes:
./ldapugmod -t group -A "description=Group C Entry" groupC
The result of the GroupC entry is as follows:
120 Administering LDAP-UX Client Services