Using Special Characters

Hat Enterprise Linux i386, in the /usr/lib64/mozldap directory on 64-bit versions of Red Hat Enterprise Linux and Solaris, and in the /opt/dirsrv/bin/mozldap/ directory on HP-UX. When running any LDAP command, make sure to use the MozLDAP utilities, otherwise the command will return errors.

NOTE

For most Linux systems, OpenLDAP tools are already installed in the /usr/bin/ directory. These OpenLDAP tools will not work for Directory Server operations.

This section contains information about the following topics:

Section 2.1, “Using Special Characters”

Section 2.2, “ldapsearch Command-Line Format”

Section 2.3, “Commonly Used ldapsearch Options”

Section 2.4, “ldapsearch Examples”

2.1. Using Special Characters

When using the ldapsearch command-line utility, it may be necessary to specify values that contain characters that have special meaning to the command-line interpreter, such as space ( ), asterisk (*), or backslash (\). Enclose the value which has the special character in quotation marks (""). For example:

-D "cn=Barbara Jensen,ou=Product Development,dc=example,dc=com"

Depending on the command-line interpreter, use either single or double quotation marks. In general, use single quotation marks (') to enclose values. Use double quotation marks (") to allow variable interpolation if there are shell variables. Refer to the operating system documentation for more information.

2.2. ldapsearch Command-Line Format

The ldapsearch command must use the following format:

ldapsearch [optional_options] [optional_search_filter] [optional_list_of_attributes]

optional_options is a series of command-line options. These must be specified before the search filter, if any are used.

553

Page 573
Image 573
HP UX Red Hat Direry Server Software Ldapsearch Command-Line Format, Ldapsearch command must use the following format