JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle Fusion Middleware Administration Guide for Oracle Unified Directory 11g Release 1 (11.1.1)
search filter icon
search icon

Document Information

Preface

1.  Starting and Stopping the Server

2.  Configuring the Server Instance

3.  Configuring the Proxy Components

4.  Configuring Security Between Clients and Servers

5.  Configuring Security Between the Proxy and the Data Source

6.  Managing Oracle Unified Directory With Oracle Directory Services Manager

7.  Managing Directory Data

Importing and Exporting Data

Populating a Stand-Alone Directory Server With Data

Importing Data Using import-ldif

import-ldif Operation Modes

To Import Data in Offline Mode

To Replace Existing Data During an Offline Import

To Append Imported Data to Existing Data

To Import Fractional Files

To Import Fractional Files by Using Filters

To Include or Exclude Attributes During Import

To Import a Compressed LDIF File

To Record Rejected or Skipped Entries During Import

To Import Data From a MakeLDIF Template

To Run an Import in Online Mode

To Schedule an Import

Exporting Data Using export-ldif

export-ldif Operation Modes

To Export Data to LDIF

To Export Partial Data

To Export Part of a Back End by Using Filters

To Include or Exclude Attributes During Export

To Export to LDIF and Then Compress the File

To Run an Export in Online Mode

To Schedule an Export

Creating MakeLDIF Template Files

The Template File Format

Custom Tag Includes

Global Replacement Variables

Branch Definitions

Template Definitions

make-ldif Template File Tags

Standard Replacement Tags

Attribute Value Reference Tags

Tag Evaluation Order

Defining Custom Tags

Importing Large Data Sets

Setting the Import Options

Tuning the JVM and Java Arguments

Backing Up and Restoring Data

Overview of the Backup and Restore Process

Backing Up Data

To Back Up All Back Ends

To Back Up All Back Ends with Encryption and Signed Hashes

To Perform an Incremental Backup on All Back Ends

To Back Up a Specific Back End

To Perform an Incremental Backup on a Specific Back End

To Schedule a Backup as a Task

Backing Up the Server Configuration

Backing Up for Disaster Recovery

To Back Up the Directory Server For Disaster Recovery

Backing up and Restoring Data Using File System Snapshots

To Take a ZFS Snapshot On a Dedicated Backup Server

To Restore a Directory Server From a ZFS Snapshot

Restoring Data

To Restore a Back End

To Restore a Back End From Incremental Backups

To Schedule a Restore as a Task

To Restore the Configuration File

To Restore a Directory Server During Disaster Recovery

Restoring Replicated Directory Servers

Deleting Backup Data

To Delete Backup Files

Searching Directory Data

Overview of the ldapsearch Command

ldapsearch Location and Format

Common ldapsearch Options

Understanding Search Criteria

Specifying Filter Types and Operators

Using Compound Search Filters

Using UTF-8 Encoding in Search Filters

Using Special Characters in Search Filters

ldapsearch Examples

To Return All Entries

To Search For a Specific User

To Search for Specific User Attributes

To Perform a Search With Base Scope

To Perform a Search With One-Level Scope

To Perform a Search With Subtree Scope

To Return Attribute Names Only

To Return User Attributes Only

To Return Base DNs Only

To Search For Specific Object Classes

To Return a Count of All Entries in the Directory

To Perform a Search With a Compound Filter

To Perform a Search Using a Filter File

To Limit the Number of Entries Returned in a Search

Searching Data With Oracle Directory Services Manager

Perform a Complex LDAP Search

Using Advanced Search Features

Searching for Special Entries and Attributes

To Search for Operational Attributes

To Search the Root DSE Entry

To Search for ACI Attributes

To Search the Schema Entry

To Search the Configuration Entry

To Search the Monitoring Entry

Searching Over SSL

To Search Over SSL With Blind Trust

To Search Over SSL Using a Trust Store

To Search Over SSL With No Trust Store

To Search Over SSL Using a Keystore

To Search Using StartTLS

To Search Using SASL With DIGEST-MD5 Client Authentication

To Search Using SASL With the GSSAPI Mechanism

To Search Using SASL With the PLAIN Mechanism

Searching Using Controls

To View the Available Controls

To Search Using the Account Usability Request Control

To Search Using the Authorization Identity Request Control

To Search Using the Get Effective Rights Control

To Search Using the LDAP Assertion Control

To Search Using the LDAP Subentry Control

To Search Using the Manage DSA IT Control

To Search Using the Matched Values Filter Control

To Search Using the Password Policy Control

To Search Using the Persistent Search Control

To Search Using the Proxied Authorization Control

To Search Using the Server-Side Sort Control

To Search Using the Simple Paged Results Control

Searching Using the Virtual List View Control

To Search Using the Virtual List View Control

To Search Using Virtual List View With a Specific Target

To Search Using Virtual List View With a Known Total

Searching in Verbose Mode and With a Properties File

To Search in Verbose Mode

To Search Using a Properties File

Searching Internationalized Entries

Examples

Supported Collation Rules

Adding, Modifying, and Deleting Directory Data

Adding Directory Entries

To Create a Root Entry

To Add an Entry Using the --defaultAdd Option With ldapmodify

To Add Entries Using an LDIF Update Statement With ldapmodify

Adding Attributes

To Add an Attribute to an Entry

To Add an ACI Attribute

To Add an International Attribute

Modifying Directory Entries

To Modify an Attribute Value

To Modify an Attribute With Before and After Snapshots

To Delete an Attribute

To Change an RDN

To Move an Entry

Deleting Directory Entries

To Delete an Entry With ldapmodify

To Delete an Entry With ldapdelete

To Delete Multiple Entries by Using a DN File

Indexing Directory Data

Configuring Indexes on the Local DB Back End

To Create a New Local DB Index

Configuring VLV Indexes

To Create a New VLV Index

Reducing Stored Data Size

To Enable or Disable Compact Encoding

To Enable or Disable Entry Compression

Ensuring Attribute Value Uniqueness

Overview of the Unique Attribute Plug-In

Configuring the Unique Attribute Plug-In Using dsconfig

To Ensure Uniqueness of the Value of the uid Attribute

To Ensure Uniqueness of the Value of Any Other Attribute

Replication and the Unique Attribute Plug-In

Configuring Virtual Attributes

To List the Existing Virtual Attributes

To Create a New Virtual Attribute

To Enable or Disable a Virtual Attribute

To Display the Configuration of a Virtual Attribute

To Change the Configuration of a Virtual Attribute

Using Collective Attributes

Extensions to the Collective Attributes Standard

Naming Collective Attributes

Collective Attributes and Conflict Resolution

Excluding Collective Attributes From Specific Entries

Configuring Collective Attributes

To Create a New Collective Attribute

To Delete a Collective Attribute

To List the Collective Attributes That Apply to an Entry

Inherited Collective Attributes

Specifying Inherited Collective Attributes

Configuring Referrals

Configuring LDAP URLs

Example LDAP URLs

To Create a Referral

To Modify a Referral

To Delete a Referral

Managing Data With Oracle Directory Services Manager

Display Entries

View the Attributes of an Entry

Search for Entries

Add an Entry

Add an Entry Based on an Existing Entry

Delete an Entry

Delete an Entry and its Subtree

Modify an Entry's RDN

Import Data From an LDIF File

Export Data to an LDIF File

8.  Replicating Directory Data

9.  Controlling Access To Data

10.  Managing Users and Groups With dsconfig

11.  Managing Password Policies

12.  Managing Directory Schema

13.  Monitoring Oracle Unified Directory

14.  Tuning Performance

15.  Advanced Administration

Ensuring Attribute Value Uniqueness

A directory's structure requires that distinguished names be unique to identify the object and its place in the directory information tree. The directory server provides a Unique Attribute plug-in, which ensures that the value of an attribute is unique when the attribute is added, modified, or moved within the directory.

Overview of the Unique Attribute Plug-In

The unique attribute plug-in is disabled by default. You can enable the plug-in by using the dsconfig command and can define the suffix and attributes that it should check. When it is enabled, the plug-in identifies whether an LDAP add, modify, or modify DN operation causes two entries to have the same attribute value before the database is updated by the operation. If the server recognizes a conflict, the operation is terminated and an LDAP_CONSTRAINT_VIOLATION error is returned to the client.

When you enable attribute uniqueness on an existing directory, the server does not check for uniqueness among existing entries. After the plug-in is enabled, uniqueness is enforced when an entry is added, modified, or moved.

The unique attribute plug-in can be configured to enforce uniqueness in one or more subtrees in the directory or among entries of a specific object class. You can define several instances of the unique attribute plug-in if you want to enforce the uniqueness of other attributes. Typically, you define one plug-in instance for each attribute whose value must be unique. You can also have several plug-in instances for the same attribute to enforce "separate" uniqueness in several sets of entries.

The unique attribute plug-in is disabled by default, so that multi-master replication configuration is not affected. When the plug-in is enabled, it checks that the uid attribute is unique prior to any add, modify, or modify DN operations for stand-alone systems and checks for uniqueness after synchronization in replicated environments.

Like other plug-ins, the unique attribute plug-in is configured by using the dsconfig command. For more information, see Configuring Plug-Ins With dsconfig. The easiest way to configure plug-ins is to use dsconfig in interactive mode. Interactive mode functions like a wizard and walks you through the plug-in configuration. Because the interactive mode is self-explanatory, the examples in this section do not demonstrate interactive mode, but provide the equivalent complete dsconfig commands.

Configuring the Unique Attribute Plug-In Using dsconfig

The following procedures explain how to configure attribute value uniqueness.

To Ensure Uniqueness of the Value of the uid Attribute

The unique attribute plug-in checks the uid attribute by default. The following task enables the unique attribute plug-in, and sets the base DN under which attribute value uniqueness for the uid attribute should be checked.

  1. (Optional) Display the plug-ins that are currently defined in the server.
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      list-plugins

    Depending on your installation, the output will be similar to the following.

    Plugin                          : Type                            : enabled
    --------------------------------:---------------------------------:--------
    7-Bit Clean                     : seven-bit-clean                 : false
    Change Number Control           : change-number-control           : true
    Entry UUID                      : entry-uuid                      : true
    LastMod                         : last-mod                        : true
    LDAP Attribute Description List : ldap-attribute-description-list : true
    Password Policy Import          : password-policy-import          : true
    Profiler                        : profiler                        : true
    Referential Integrity           : referential-integrity           : false
    UID Unique Attribute            : unique-attribute                : false
  2. (Optional) Display the properties that are configured for the unique attribute plug-in
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      get-plugin-prop \
      --plugin-name "UID Unique Attribute" \
    Property : Value(s)
    ---------:---------
    base-dn  : -
    enabled  : false
    type     : uid
  3. Enable the unique attribute plug-in.
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      set-plugin-prop \
      --plugin-name "UID Unique Attribute" --set enabled:true
  4. Set the base DN under which uniqueness is checked.
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      set-plugin-prop \
      --plugin-name "UID Unique Attribute" --set base-dn:ou=People,dc=example,dc=com

To Ensure Uniqueness of the Value of Any Other Attribute

The unique attribute plug-in checks the uid attribute by default. If you want to ensure uniqueness for a different attribute, create a new instance of the unique attribute plug-in and set its type property.

This example creates a new instance of the unique attribute plug-in and ensures uniqueness of the mail attribute.

  1. Create and enable a new instance of the unique attribute plug-in.

    Set the type property to the name of the attribute that should be unique (in this case, mail.

    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      create-plugin \
      --type unique-attribute --plugin-name "MAIL unique attribute"
      --set enabled:true --set type:mail
  2. Enable the new unique attribute plug-in.
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      set-plugin-prop \
      --plugin-name "MAIL Unique Attribute" --set enabled:true
  3. Set the base DN under which uniqueness is checked.
    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      set-plugin-prop \
      --plugin-name "MAIL Unique Attribute" --set base-dn:ou=People,dc=example,dc=com
  4. Specify the attribute whose value must be unique.

    This example specifies the mail attribute.

    $ dsconfig -h localhost -p 4444 -D "cn=directory manager" -w password -n \
      set-plugin-prop \
      --plugin-name "MAIL Unique Attribute" --set type:mail
Next Steps

To ensure that the values of more than one attribute are unique, create and enable multiple instances of the unique attribute plug-in.

Replication and the Unique Attribute Plug-In

The Unique Attribute plug-in does not check attribute uniqueness when an update is performed as part of a replication operation. To ensure attribute value uniqueness in a replication environment, enable the unique attribute plug-in for the same attribute in the same subtree on all servers in the topology.