Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Setting Up Application Data

Updated: August 22, 2005

Applies To: Windows Server 2003 R2

In most cases, you extend the ADAM schema with object class and attribute definitions for the kinds of data that you want an application to store. Just as with Active Directory, the schema in ADAM is extensible. You can extend the ADAM schema programmatically or with the Ldifde.exe command-line tool.

In the following exercises, you:

  • Step 1: Add optional user classes to the ADAM schema.

  • Step 2: Extend the ADAM schema to support an application.

  • Step 3: Import application data into an ADAM instance.

noteNote
You will use the application data that you import in these exercises later with the Windows Address Book application.

Step 1: Adding Optional User Classes to the ADAM Schema

You can add the optional user classes that are provided with ADAM during ADAM setup, or you can add them manually using the Ldifde.exe command-line tool. If you imported the user class definition .ldf files when you ran the Active Directory Application Mode Setup Wizard, you can skip this procedure.

To manually add optional user classes to the ADAM schema

  1. Click Start, point to All Programs, point to ADAM, and then click ADAM Tools Command Prompt.

  2. At the command prompt, type the following command, and then press ENTER:

    ldifde -i -f ms-inetorgperson.ldf -s servername:portnumber -k -j . -c "CN=Schema,CN=Configuration,DC=X" #schemaNamingContext

    where servername:portnumber represents the computer name and LDAP communication port of your ADAM instance. Because the ADAM instance is running on your local computer, you can also use localhost as the computer name.

    noteNote
    Be sure to use the copy of Ldifde.exe that came with Windows Server 2003 R2, rather than a copy that came with an earlier ADAM release or with Windows Support Tools.

    The ADAM Tools Command Prompt window should now look like the following:

    ADAM ldifde ms-inetorgperson.ldf
  3. Type the following command, and then press ENTER:

    ldifde -i -f ms-user.ldf -s servername:portnumber -k -j . -c "CN=Schema,CN=Configuration,DC=X" #schemaNamingContext

    The ADAM Tools Command Prompt window now looks like the following:

    ADAM ldifde ms-user.ldf

    After you run these commands, the ADAM schema includes the ADAM and inetOrgPerson user object classes. You can verify this by viewing the ADAM schema with the ADAM Schema snap-in.

Step 2: Extending the ADAM Schema to Support an Application

In this exercise, you extend the ADAM schema again by adding a contacts object class, again by using the ldifde command-line tool.

To extend the ADAM schema

  1. Click Start, point to All Programs, point to ADAM, and then click ADAM Tools Command Prompt.

  2. At the command prompt, type the following, and then press ENTER:

    ldifde -i -f drive:\path \labs_demo\labs\contact.ldf -s servername:portnumber-k -j . -c "CN=Schema,CN=Configuration" #schemaNamingContext

    where drive:\path represents the location where you saved the ADAM download, and servername:portnumber represents the computer name and LDAP communications port of your ADAM instance. Because the ADAM instance is running on your local computer, you can also use localhost as the computer name.

    noteNote
    Be sure to use the copy of Ldifde.exe that came with the ADAM release, rather than a copy that came with an earlier ADAM release or with Windows Support Tools.

    After the command runs, the ADAM Tools Command Prompt window looks like the following:

    ADAM ldifde contact.ldf

Now your ADAM schema also includes the contacts object class, and it is ready for some application data.

Step 3: Importing Application Data into an ADAM Instance

In this exercise, you import some sample data into your ADAM instance using the ldifde command-line tool. This data is provided with the ADAM download.

To import application data

  1. Click Start, point to All Programs, point to ADAM, and then click ADAM Tools Command Prompt.

  2. At the command prompt, type the following:

    ldifde -i -f drive:\path \labs_demo\labs\contactimport.ldf -s servername:portnumber -k -j .

    where drive:\path represents the location where your ADAM files are located, and servername:portnumber represents the computer name and LDAP communications port of your ADAM instance.

    noteNote
    Be sure to use the copy of Ldifde.exe that came with the ADAM release, rather than a copy that came with an earlier ADAM release or with Windows Support Tools.

    After the command runs, the ADAM Tools Command Prompt window looks like the following:

    ADAM ldifde contactimport.ldf
    noteNote
    Ldifde always reports the number of entries that are imported into the directory. In this case, you can see from the ldifde output that contactimport.ldf contains two records. For more information about ldifde, type ldifde /? at the command prompt.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.