Share via


Using the LDIFDE Tool

Using the LDIFDE Tool

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

Microsoft® Active Directory® stores information about its objects in the NTDS.DIT database. Each object in Active Directory is classified and located using a unique Domain Name System (DNS) name. Though Active Directory is fully integrated with the DNS namespace, DNS handles only part of the task of locating Active Directory objects. DNS servers identify servers on the network that are running the LDAP service. An LDAP server handles the details of locating a specific Active Directory object in the database.

The LDAP Data Interchange Format (LDIF) is a standard for a file format that is used in LDAP implementations. The LDAP Data Interchange Format Data Exchange (LDIFDE) tool is a utility program that can be used to import and export Active Directory objects using LDIF-formatted files. LDIFDE is especially useful for doing batch operations that allow you to add, create, or modify multiple Active Directory objects at one time.

The LDIFDE tool is run from the command prompt, and includes several switches that direct the import or export operation.

The LDIFDE syntax is:

ldifde  switch1 switch1_data switch2 switch2_data...

The following is the command line to extend the Active Directory schema for the Sample Gateway:

ldifde -i -v -f samplegw.ldf -c "<SchemaContainerDN>""CN=Schema,CN=Configuration,DC=...,DC=..."

This command tells the LDIFDE tool to import the contents of the file samplegw.ldf into the Active Directory schema. The specific switches include the following:

Switch Description
-i Indicates that this is an import operation. The default is export.
-v Turns on verbose mode.
-f filename Specifies the name of the file from which the data is imported, in this case samplegw.ldf. This switch is also used to specify the name of a data export file.
-c fromDN toDN Replaces all occurrences of fromDN with toDN. This switch is generally used when data is imported from one domain to another and the distinguished name of the export domain needs to be replaced with that of the import domain.

For more information about the LDIFDE tool, see Microsoft Windows® 2000 documentation.

Send us your feedback about the Microsoft Exchange Server 2003 SDK.

Build: June 2007 (2007.618.1)

© 2003-2006 Microsoft Corporation. All rights reserved. Terms of use.