Previous Next Contents Index


Chapter 15 NT Directory Synchronization

The Netscape Directory Server NT Synchronization service allows you to synchronize the entries in your Windows NT directory with the entries in your Netscape Directory Server directory. Both NT users and NT groups can be synchronized. As entries are created, modified, or deleted in one directory, the synchronization service makes the corresponding change to the other directory.

Directory synchronization occurs in both directions: NT to directory server and directory server to NT. All NT account information, including passwords, can be synchronized. There are no requirements as to which environment (the NT domain or the directory server) you use to master NT directory data. However, you are recommended to master directory data in just one environment, because this will simplify the administration of your NT accounts. By strictly identifying where and how NT account information is changed, you greatly reduce the chance of conflicts and errors in the management of this information.

The NT Synchronization Service requires the following versions of the directory server:

This chapter contains information about using the NT Synchronization Service in the following sections:


The Synchronization Service
NT directory synchronization is performed using the Netscape directory synchronization service. This service can be configured to automatically synchronize your directories based on a schedule that you supply.

Note. A Netscape directory subtree can be managed by one and only one synchronization service; synchronization services from different NT hosts must manage account information in different branches of the directory tree. Moreover, a synchronization service on an NT host can manage multiple subtrees: one for user information and one for group information.

Synchronization: NT to Directory Server

Each NT domain can be synchronized with one and only one directory server. If you are using replication in your directory service, make sure that the directory server that you synchronize with is a supplier server; do not synchronize with a consumer server.

To perform synchronization, the synchronization service examines the local NT directory for changes and then transfers these changes to the directory server using an LDAPS (LDAP over SSL) or LDAP connection.

Note. You can not set up two synchronization services so that two separate NT domains are synchronized to a single directory subtree. The directory server includes a plug-in that prevents this from happening. This is prevented because unique user IDs are ensured within an NT domain, but not within multiple NT domains in the same network. Therefore, if you were to synchronize multiple NT domains to a single directory subtree, you would run the risk of DN conflicts.

How NT Directory Changes Are Discovered

The synchronization service finds changes in the NT directory by using two methods:

All NT directory changes can be transferred to the directory server using LDAPS (LDAP over SSL) which ensures the privacy of the NT user and group information. This is the recommended configuration for the synchronization service, although you can configure the synchronization service such that it does not use LDAPS for directory server communications.

Creating User Entries

When you create an NT user account, the synchronization service can automatically create a corresponding entry on the directory server. The new entry is created in the subtree that you identify when you configure the synchronization service.

The new directory server entry is created using the inetOrgPerson and NTUser object classes. NTUser attributes are set as described for the NTUser object class definition in the Netscape Directory Server Schema Reference manual.

In addition, the following inetOrgPerson attributes are set:

In addition, if the synchronization service has been told to automatically create messaging server accounts, then the mailRecipient and nsLicenseUser object classes are set on the new directory server account and the following attribute values are set on the entry:

Creating Group Entries

When you create an NT group, the synchronization service can automatically create a corresponding group entry on the directory server. The new group is created in the subtree that you identify when you configure the synchronization service.

The new directory server group entry is created using the groupOfUniqueNames and NTGroup object classes. NTGroup attributes are set as described for the NTGroup object class definition in the Netscape Directory Server Schema Reference manual. Specifically, the ntGroupDomainID attribute is set with the following value:

ntGroupDomainID: <NT domain name>:<NT Group Name>

The ntGroupType attribute is also set with a value of local or global.

In addition, the following groupOfUniqueNames attributes are set:

Initially Creating Entries

When you first start the synchronization service, the service does not automatically add any existing NT users to the directory server. To have existing NT users added to the directory server, use the "Add all users and groups" button in the Synchronization Schedule tab.

This causes the synchronization service to add every currently existing user and group to the directory server. The new directory server entries are created as described in "Creating User Entries" on page 358.

Synchronization: Directory Server to NT

Each directory server can communicate with multiple synchronization services. Consequently, the directory server tree should be structured such that all of the NT user entries from a given NT domain are collected within a single directory server subtree. If the directory server is synchronizing with multiple NT domains, then a separate directory server subtree should be used for each NT domain.

How Synchronization Occurs

The directory server uses a LDAP SSL (LDAPS) or LDAP connection to communicate with the NT synchronization service. The directory server uses this connection to:

Because of the importance of this non-LDAP connection, the synchronization service cannot be started if the corresponding directory server is not listening on the port defined for this communication.

Note. Changes made to the directory server can only be synchronized to NT if those changes are made over LDAP (that is, if they are made using any LDAP client such as the gateway or the various LDAP command line tools). However, if NT users or groups are created using ldif2db, then those entries will never be discovered by the synchronization service and they will never be synchronized with the NT directory.

Creating User Entries

The NT synchronization service can create an NT user account on the local NT host if the following conditions are true:

In this situation, the synchronization service creates the new user based on the following information:

Creating Group Entries

The NT synchronization service will create an NT group on the local NT host if the following conditions are true:

In this situation, the synchronization service creates the new group based on the following information:

Creating Duplicate Entries

If an entry is created in the directory server, and the NT user account identified by the ntUserDomainID attribute already exists, then the synchronization service's behavior is dependent upon the directory server entry's ntUserCreateNewAccount attribute. Similarly, if a group is created in the directory server, and the NT group account identified by the ntGroupDomainID attribute already exists, then the synchronization service's behavior is determined by the ntGroupCreateNewAccount attribute.

If the ntUserCreateNewAccount or ntGroupCreateNewAccount attribute does not exist on the entry or if this attribute is set to false, then the synchronization service will attempt to modify the existing NT group or user account with the common name and description information stored on the directory server entry.

If the ntUserCreateNewAccount or ntGroupCreateNewAccount attribute is set to true, then the synchronization service will report an error indicating that it attempted to create the new group or user account but that it already existed.

Deleting Entries

The NT synchronization service will delete an NT group or user account if the following conditions are true:

Modifying Entries

The synchronization service can modify a user or group account on the local NT host any time the corresponding directory server entry is modified. For details on how this synchronization process occurs, see "How Synchronization Occurs" on page 358.

Associating an Existing Directory User with an NT User Account

If you have an existing directory (LDAP) user entry, and that entry resides in the directory subtree that the synchronization service is monitoring, you can associate the entry with a new or existing NT user account.

You do this by adding the ntUser object class and the required ntUserDomainID attribute to the entry. If the NT user account does not currently exist, use the ntUserCreateNewAccount attribute to cause the synchronization service to create the NT user account for you.

For example, the following LDIF statements associates the existing directory user entry with the rhunt user ID in the CHURCHFIELD NT domain. The description and ntUserDeleteAccount attributes that are set in the LDIF are optional. If that NT user does not exist, the synchronization service will create it:

dn: uid=rhunt, ou=people, o=Airius.com
changetype: modify
add: objectclass
objectclass: ntUser
-
add:ntUserDomainID
ntUserDomainID: CHURCHFIELD:rhunt
-
add: ntUserCreateNewAccount
ntUserCreateNewAccount: true
-
add: description
description: a new NT user
-
add:ntUserDeleteAccount
ntUserDeleteAccount: true

Associating an Existing Directory Group with an NT Group

If you have an existing directory (LDAP) group entry, and that entry resides in the directory subtree that the synchronization service is monitoring, you can associate the entry with a new or existing NT group account.

You do this by adding the ntGroup object class and the required ntGroupDomainID attribute to the entry. If the NT group account does not currently exist, use the ntGroupCreateNewGroup attribute to cause the synchronization service to create the NT group account for you.

For example, the following LDIF statements associates the existing directory group entry with the NT PD Managers group in the CHURCHFIELD NT domain. The description, ntGroupDeleteGroup, and ntGroupType attributes that are set in the LDIF are optional. If that NT group does not exist, the synchronization service will create it:

dn: cn=PD Managers, ou=groups, o=Airius.com
changetype: modify
add: objectclass
objectclass: ntGroup
-
add:ntGroupDomainID
ntGroupDomainID: CHURCHFIELD:NT PD Managers
-
add: ntGroupType
ntGroupType: local
-
add: ntGroupCreateNewGroup
ntGroupCreateNewGroup: true
-
add: description
description: a new NT group
-
add:ntGroupDeleteGroup
ntGroupDeleteGroup: true

Dissassociating a Directory User or Group from an NT User or Group

You can break the association between a directory (LDAP) user or group and a corresponding NT entry without deleting either entry. You do this by deleting the ntUser or ntGroup object class from the entry and all corresponding attributes.

For example, the following LDIF deletes the ntUser object class from the directory entry and then deletes all the attributes that are allowed by that object class. Doing so causes the synchronization service to no longer synchronize changes made to the directory entry:

dn: uid=rhunt, ou=people, o=Airius.com
changetype: modify
delete: objectclass
objectclass: ntUser
-
delete:ntUserDomainID
-
delete: ntUserCreateNewAccount
-
delete: description
description: a new NT user
-
delete:ntUserDeleteAccount

Concurrently Changing Directory Server and NT Account Values

Because NT synchronization can be configured to synchronize in two directions, NT to directory server and directory server to NT, there is a potential for losing data. This can happen if you change corresponding entries in both directories before synchronization can occur. For example, if you change an NT user account's comment field and you also change the corresponding directory server entry's description field before the synchronization service can transfer the comment field changes, then you will lose the change that was made first.

The window of opportunity for losing data is driven entirely by the schedule that you set up for NT to directory server synchronization. This is because the directory server to NT synchronization occurs as soon as changes are made on the directory server. If you make a change on the NT domain, and then make a conflicting change in the directory server before NT to directory server synchronization happens, then the changes to the NT domain will be lost.

Make a habit out of changing NT values in only one of the two directories. This will reduce potential confusion and help to avoid any problems that might occur because of conflicting changes in the two directories.


The Synchronization Configuration Tool
You configure and control directory synchronization using the directory server NT synchronization configuration tool.

This tool is a native Windows NT application that you use to:

This tool is installed with the NT synchronization service. You can install the NT synchronization service when you install the directory server, or you can install it after the directory server has been installed.

Also, the directory server does not have to be installed on the same physical host as the NT synchronization service; the two can exist on entirely different machines. Additionally, the directory server does not have to be running under NT; the synchronization service will work with directory servers running under Unix operating systems.

About the OK, Cancel, Apply, and Help Buttons

The configuration tool contains four standard buttons:

Configuring Synchronization

To set up NT synchronization, you must:

Configuring Service Settings

Use the Service Settings tab to identify the following about the synchronization service:

If you want to disable NT to directory server synchronization, click Disable Synchronization from NT to Directory Server.

Configuring Directory Server Settings

Use the Directory Server Settings tab to identify the following information:

Note. If the name of the directory subtree you want to use as the directory base for either users or groups contains a comma, you must escape the comma with a backslash (\) when you enter the value in the directory base field. For example, to use the Airius Bolivia, S.A. subtree as the directory base, you would enter Airius Bolivia\, S.A. in the directory base field.

If the Selected UID is Not Unique

If the synchronization service attempts to create a directory entry, and the proposed UID that the synchronization service wants to use is not unique, then the synchronization service:

  1. creates the directory entry
  2. issues a warning message to the NT Event Log and to the synchronization service's log file (for information on this log file, see "Configuring Service Settings" on page 366)
Scheduling Synchronization

Use the Synchronization Schedule tab to schedule NT to directory server synchronization.

There is no scheduling area for directory server to NT synchronization, because that synchronization always occurs as soon as relevant directory server data is changed.

You use the following two fields to schedule synchronization:

The next scheduled synchronization event for each direction is always shown in the "Next synchronization at" field.

Manually Performing Synchronization

While synchronization will always occur based on the schedule set in the synchronization configuration tool, you can manually perform synchronization if you have an immediate need for a synchronization to occur.

To manually perform synchronization, go to the Status tab in the synchronization configuration tool, and click the "Synchronize" button.

The synchronization schedule you have set in the configuration tool is unaffected by this manual synchronization. That is, if a synchronization is scheduled for 1:30 and you perform a synchronization at 1:25, then the 1:30 synchronization will still occur.

Configuring Account Details

Use the Account Details tab to indicate whether the synchronization service should create mail accounts on the directory server when creating new ntUser entries on the directory server.

To cause mail accounts to be created, click "Automatically create Messaging Server accounts for new Directory Server users."

You must then identify the following information:

Surname-based NT Accounts

Some cultures commonly begin their names with their surnames. If your NT domain is populated with names such as these, then you must configure the synchronization service with this information so that it can determine how to populate the surname and givenname attributes for the NT user entries. To do this, go the Account Details tab in the synchronization configuration tool and select "NT account full name begins with surname."

Starting and Stopping the Synchronization Service

Use the Status tab to start and stop the synchronization service.

The service is not running when it is first installed. However, the service is configured to automatically start when your NT system reboots. To reconfigure the service so that it does not start when NT reboots:

  1. Go to the NT Control Panel, and select Services.
  2. Scroll through the list of services until you see Netscape Directory Synchronization Service. The Startup field is set to Automatic.
  3. Double-click on Netscape Directory Synchronization Service.
  4. Select the Manual radio button, and then click OK.
  5. Click Close in the Services control panel.
Checking Synchronization Status

You can use the synchronization configuration tool to check synchronization status. From the Status area, you can determine:


Turning Off SSL for the Synchronization Service
You are strongly recommended to use SSL for NT to directory synchronization because of the sensitive nature of the information that you are synchronizing. However, you may feel that SSL is unnecessary, especially if you are using the synchronization service in a non-production (lab) environment. Do the following to cause the synchronization service to not use SSL when synchronizing with your directory server.

  1. On the Directory Server Console, select the Configuration tab and then select the root entry in the navigation tree in the left pane.
  2. Select the Settings tab in the right pane.
  3. Clear the "Use SSL in NT Synchronization Service" checkbox.
  4. Click Save and then restart the server. See  "Starting and Stopping the Directory Server" for more information.
  5. Go to the Service Settings tab in the NT Synchronization Configuration Tool and make sure that "Use SSL" is not selected.
  6. In the Directory Server Settings tab, make sure the LDAP port is not set to 636 (it should probably be 389).
  7. Save your changed settings and restart the synchronization service.

Troubleshooting Errors at Synchronization Time
If your synchronization service is not properly configured, synchronization does not occur and a message box is raised by the configuration tool indicating the error.

The message box indicates that the directory base DNs and/or other configuration attributes are not correct. Ensure that the directory base DNs, and the administrator DN and password are correct. Also verify that the port numbers used for LDAP/LDAPS and the synchronization plug-ins match on the directory server and the synchronization service.

If the message box indicates error 81, then the synchronization service and/or the directory server have not been properly configured for SSL communications. Examine the directory server access log file to see if the connection attempt was received by the directory server. You may also find helpful messages in the directory server's error log file.

To narrow down the source of the misconfiguration, try to establish an LDAPS connection to the directory server using Netscape Communicator. If this connection attempt fails, check all values (port number, host name, search base, and so forth) to see if any of these are the problem. If all else fails, reconfigure the directory server with a new certificate.

Note. A common problem is to fail to trust your certificate authority when configuring synchronization service's certificate database. For information on how to create a certificate database, see "Creating Certificate Databases for LDAP Clients" on page 304.

If the Communicator connection is successful, it is likely that the misconfiguration is on the synchronization service side. Recheck all configuration values and examine the synchronization log file for error messages. To help you determine whether the problem is with SSL configuration or general synchronization service configuration, turn off SSL for synchronization and make sure that synchronization is working. Wait until everything is working before you try to configure the synchronization service with SSL.

 

© Copyright 1999 Netscape Communications Corporation, a subsidiary of America Online, Inc. All Rights Reserved.