1LDAPMODRDN(1) General Commands Manual LDAPMODRDN(1)
2
3
4
6 ldapmodrdn - LDAP rename entry tool
7
9 ldapmodrdn [-r] [-s newsup] [-n] [-v] [-c] [-M[M]] [-d debuglevel]
10 [-D binddn] [-W] [-w passwd] [-y passwdfile] [-H ldapuri] [-h ldaphost]
11 [-p ldapport] [-P {2|3}] [-e [!]ext[=extparam]] [-E [!]ext[=extparam]]
12 [-O security-properties] [-I] [-Q] [-U authcid] [-R realm] [-x]
13 [-X authzid] [-Y mech] [-Z[Z]] [-f file] [dn rdn]
14
16 ldapmodrdn is a shell-accessible interface to the ldap_rename(3)
17 library call.
18
19 ldapmodrdn opens a connection to an LDAP server, binds, and modifies
20 the RDN of entries. The entry information is read from standard input,
21 from file through the use of the -f option, or from the command-line
22 pair dn and rdn.
23
25 -r Remove old RDN values from the entry. Default is to keep old
26 values.
27
28 -s newsup
29 Specify a new superior entry. (I.e., move the target entry and
30 make it a child of the new superior.) This option is not sup‐
31 ported in LDAPv2.
32
33 -n Show what would be done, but don't actually change entries.
34 Useful for debugging in conjunction with -v.
35
36 -v Use verbose mode, with many diagnostics written to standard out‐
37 put.
38
39 -c Continuous operation mode. Errors are reported, but ldapmod‐
40 rdn will continue with modifications. The default is to
41 exit after reporting an error.
42
43 -M[M] Enable manage DSA IT control. -MM makes control critical.
44
45 -d debuglevel
46 Set the LDAP debugging level to debuglevel. ldapmodrdn must be
47 compiled with LDAP_DEBUG defined for this option to have any
48 effect.
49
50 -f file
51 Read the entry modification information from file instead of
52 from standard input or the command-line.
53
54 -x Use simple authentication instead of SASL.
55
56 -D binddn
57 Use the Distinguished Name binddn to bind to the LDAP directory.
58 For SASL binds, the server is expected to ignore this value.
59
60 -W Prompt for simple authentication. This is used instead of spec‐
61 ifying the password on the command line.
62
63 -w passwd
64 Use passwd as the password for simple authentication.
65
66 -y passwdfile
67 Use complete contents of passwdfile as the password for simple
68 authentication.
69
70 -H ldapuri
71 Specify URI(s) referring to the ldap server(s); only the proto‐
72 col/host/port fields are allowed; a list of URI, separated by
73 whitespace or commas is expected.
74
75 -h ldaphost
76 Specify an alternate host on which the ldap server is running.
77 Deprecated in favor of -H.
78
79 -p ldapport
80 Specify an alternate TCP port where the ldap server is listen‐
81 ing. Deprecated in favor of -H.
82
83 -P {2|3}
84 Specify the LDAP protocol version to use.
85
86 -O security-properties
87 Specify SASL security properties.
88
89 -e [!]ext[=extparam]
90
91 -E [!]ext[=extparam]
92
93 Specify general extensions with -e and search extensions with
94 -E. ´!´ indicates criticality.
95
96 General extensions:
97 [!]assert=<filter> (an RFC 4515 Filter)
98 [!]authzid=<authzid> ("dn:<dn>" or "u:<user>")
99 [!]manageDSAit
100 [!]noop
101 ppolicy
102 [!]postread[=<attrs>] (a comma-separated attribute list)
103 [!]preread[=<attrs>] (a comma-separated attribute list)
104 abandon, cancel (SIGINT sends abandon/cancel; not really controls)
105
106 Search extensions:
107 [!]domainScope (domain scope)
108 [!]mv=<filter> (matched values filter)
109 [!]pr=<size>[/prompt|noprompt] (paged results/prompt)
110 [!]sss=[-]<attr[:OID]>[/[-]<attr[:OID]>...] (server side sorting)
111 [!]subentries[=true|false] (subentries)
112 [!]sync=ro[/<cookie>] (LDAP Sync refreshOnly)
113 rp[/<cookie>][/<slimit>] (LDAP Sync refreshAndPersist)
114
115 -I Enable SASL Interactive mode. Always prompt. Default is to
116 prompt only as needed.
117
118 -Q Enable SASL Quiet mode. Never prompt.
119
120 -U authcid
121 Specify the authentication ID for SASL bind. The form of the ID
122 depends on the actual SASL mechanism used.
123
124 -R realm
125 Specify the realm of authentication ID for SASL bind. The form
126 of the realm depends on the actual SASL mechanism used.
127
128 -X authzid
129 Specify the requested authorization ID for SASL bind. authzid
130 must be one of the following formats: dn:<distinguished name> or
131 u:<username>
132
133 -Y mech
134 Specify the SASL mechanism to be used for authentication. If
135 it's not specified, the program will choose the best mechanism
136 the server knows.
137
138 -Z[Z] Issue StartTLS (Transport Layer Security) extended operation. If
139 you use -ZZ, the command will require the operation to be suc‐
140 cessful.
141
143 If the command-line arguments dn and rdn are given, rdn will replace
144 the RDN of the entry specified by the DN, dn.
145
146 Otherwise, the contents of file (or standard input if no -f flag is
147 given) should consist of one or more entries.
148
149 Distinguished Name (DN)
150 Relative Distinguished Name (RDN)
151
152 One or more blank lines may be used to separate each DN/RDN pair.
153
155 Assuming that the file /tmp/entrymods exists and has the contents:
156
157 cn=Modify Me,dc=example,dc=com
158 cn=The New Me
159
160 the command:
161
162 ldapmodrdn -r -f /tmp/entrymods
163
164 will change the RDN of the "Modify Me" entry from "Modify Me" to "The
165 New Me" and the old cn, "Modify Me" will be removed.
166
168 Exit status is 0 if no errors occur. Errors result in a non-zero exit
169 status and a diagnostic message being written to standard error.
170
172 ldapadd(1), ldapdelete(1), ldapmodify(1), ldapsearch(1), ldap.conf(5),
173 ldap(3), ldap_rename(3)
174
176 The OpenLDAP Project <http://www.openldap.org/>
177
179 OpenLDAP Software is developed and maintained by The OpenLDAP Project
180 <http://www.openldap.org/>. OpenLDAP Software is derived from Univer‐
181 sity of Michigan LDAP 3.3 Release.
182
183
184
185OpenLDAP 2.4.23 2010/06/30 LDAPMODRDN(1)