LDAP Directory Synchronizer
Online Documentation

HOME NEXT PREVIOUS

Running LDSU

Once setup and configuration is complete, this chapter explains how to test and run LDSU instances and how to put together a directory synch solution.


Testing LDSU Instances

Once an LDSU instance has been configured and all the input files and/or the LDAP directory data is in place, it may be tested in one of two ways:

  1. Run LDSU from the command prompt
  2. Run an LDSU script

To run an LDSU script, see the section on Using LDSU Scripts. These provide a capsule summary of the run and save the ldsu output in the ldsu.log file which can be examined if any problems occur.

To run LDSU from the command prompt, set default to the LDSU instance subdirectory and run the following command:

The [config_file] parameter is optional and defaults to ldsu_config.dat.

All LDSU processing information is written out to STDOUT (e.g. to the terminal screen) as it happens. When running LDSU scripts, this information is saved to the ldsu.log file in the LDSU instance subdirectory. See the section on the LDSU Log Files for more information.

Two LDSU Config File parameters are useful for testing LDSU:

If LDSU is having problems accessing the LDAP Directory, the LDAP test program (ldap_test) can be employed to help troubleshoot and test LDAP access. See the section on Running LDAP_TEST on how to use it.


LDSU Log Files

LDSU has two logs:

The transaction log file is detailed in the Section on LDSU Transaction Codes.

The STDOUT log contains a series of timestamp lines which LDSU generates as they happen to tell what LDSU is doing. For example:

Jun 01 12:07:08 processing configuration file ldsu_config.dat
Jun 01 12:07:08 processing layout file [-.templates]ldsu_layout_exchange.dat
Jun 01 12:07:09 initializing and binding to Directory
...

This will be followed by a "SYNCH SUMMARY" section which lists how many records were read/written from various files and, if an IMPORT or TRANSACTION instance, LDSU will also list a summary of the LDAP Directory Add, Modify, and Delete Transactions.

Finally, a section called the "CONFIGURATION FILE SUMMARY" is output which gives the values for all the possible Configuration parameters for the current mode.

If LDSU encounters, any errors, the error is output and if a fatal error, LDSU will stop without further STDOUT messages. These errors are called Run-time errors and are documented in the Run-time error messages section.


LDSU Scripts

To help run an LDSU instance, LDSU comes with six (6) scripts in the LDSU bin subdirectory:

Each of these scripts performs the following functions:

Two (2) additional scripts are provided for user tailoring:


do_import

The do_import script does a single LDSU import.

Parameters:

The following files must already exist in the import subdirectory (P1):

The following files are optional in the import subdirectory:

The following files are created as a result of running this procedure:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
IMPORT_TEST started at Wed Jun 10 17:11:47 1998

importing import.txt to Directory

Number of successful transactions: 3
Number of failed transactions:     0
Number of successful add transactions:    0
Number of successful modify transactions: 2
Number of successful delete transactions: 1
Number of failed add transactions:    0
Number of failed modify transactions: 0
Number of failed delete transactions: 0

IMPORT_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_trans

The do_trans script does a single LDSU transaction mode import.

Parameters:

The following files must already exist in the import subdirectory (P1):

The following files are optional in the import subdirectory:

The following files are created as a result of running this procedure:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
IMPORT_TEST1 started at Wed Jun 10 17:11:47 1998

importing import.txt to Directory

Number of successful transactions: 3
Number of failed transactions:     0
Number of successful add transactions:    1
Number of successful modify transactions: 1
Number of successful delete transactions: 1
Number of failed add transactions:    0
Number of failed modify transactions: 0
Number of failed delete transactions: 0

IMPORT_TEST1 finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_import

The do_import script does a single LDSU import.

Parameters:

The following files must already exist in the import subdirectory (P1):

The following files are optional in the import subdirectory:

The following files are created as a result of running this procedure:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
IMPORT_TEST started at Wed Jun 10 17:11:47 1998

importing import.txt to Directory

Number of successful transactions: 3
Number of failed transactions:     0
Number of successful add transactions:    0
Number of successful modify transactions: 2
Number of successful delete transactions: 1
Number of failed add transactions:    0
Number of failed modify transactions: 0
Number of failed delete transactions: 0

IMPORT_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_export

The do_export script does a single LDSU export.

Parameters:

The following files must already exist in the export subdirectory (P1):

The following files are created as a result of running this procedure:

The following files are optional in the export subdirectory:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
EXPORT_TEST started at Wed Jun 10 17:11:47 1998

exporting export.txt from Directory

Old metafile records written: 2
Old metafile records read:    2

EXPORT_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_export1

The do_export1 script does a single LDSU export where directory records to export are generated from an input file.

Parameters:

The following files must already exist in the export subdirectory (P1):

The following files are created as a result of running this procedure:

The following files are optional in the export subdirectory:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
EXPORT1_TEST started at Wed Jun 10 17:11:47 1998

exporting export_output.txt from Directory

Old metafile records written: 2
Old metafile records read:    2

EXPORT1_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_change

The do_change script does a single LDSU changes export. Changes are generated by comparing what's in the Directory now and what was in the Directory the last time LDSU ran. This method uses metafiles.

Parameters:

The following files must already exist in the export subdirectory (P1):

The following files are optional in the export subdirectory:

The following files are created as a result of running this procedure:

Each Changes export creates a "changes-to-be-processed" file. (export.start) When the export_*.txt are successfully used by the post processor or the foreign directory's local import procedure, this file should be renamed to a "changes-were-processed" file (export.finish) by that procedure. If the procedure does not rename the file, changes will be regenerated the next time this export is run.

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
CHANGES_TEST started at Wed Jun 10 17:11:47 1998

exporting export_*.txt from Directory

Old metafile records read:    10
New metafile records written: 12
ADD metafile records used:    3
MOD metafile records used:    4
DEL metafile records used:    1

CHANGES_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


do_change1

The do_change1 script does a single LDSU changes export. Changes are generated by comparing what's in the Directory now against a full foreign directory import file.

Parameters:

The following files must already exist in the export subdirectory (P1):

The following files are optional in the export subdirectory:

The following files are created as a result of running this procedure:

Examples: (Default Directory is LDSU Root Directory)

Sample Output:

----------------------------------------------------------------------
CHANGES1_TEST started at Wed Jun 10 17:11:47 1998

exporting export_*.txt from Directory

Old metafile records read:    3
New metafile records written: 3
ADD metafile records used:    0
MOD metafile records used:    1
DEL metafile records used:    0

CHANGES1_TEST finished at Wed Jun 10 17:11:50 1998
----------------------------------------------------------------------


ldap_test

ldap_test is an LDAP test program which is supplied in the LDSU bin directory to help troubleshoot and test LDAP access and to determine LDAP RDN and attribute names. It is a read-only program that only does the LDAP open, bind and search functions.

Parameters:

If bind DN and Password are not supplied, then an anonymous bind is attempted.

Examples of starting ldap_test: (Default Directory is LDSU Root Directory)

Sample Output:

LDAP Search Test Program
Opening server.cop.dec.com:389
Binding
Hit Return to exit

Search Base: <enter base search context to search on or RETURN to exit>
Scope (0-Base, 1-One, 2-Subtree): <enter 0 to search one record - Default>
                                  <enter 1 to search one level down>
				  <enter 2 to search whole tree under base>
Filter [objectclass=*]: <enter an LDAP filter (e.g. surname=smith)>
                        <default is no filter - objectclass=*>
Attributes: <enter attributes to return separated by a comma>
	    <or leave blank to return all attributes - default>
0 - Values, 1 - Attrs Only: <enter 0 to return values - default>
                            <enter 1 to return names and no values>

The program then dumps all entries returned by the LDAP server in the following format:

Searching...
N Entries Found
 DN: CN=Test, O=Digital, C=US
    commonName = Test
    objectClass = Person
           = organizationalPerson
    Surname = Test
 DN: ...

Note that many LDAP directories have certain attributes that are not returned unless they are specifically asked for (i.e. Not returned in "all attributes"). In addition, the privileges or access level associated with the bind name (or an anonymous bind) may restrict access to certain attributes.


Creating an LDSU Solution

When all LDSU instances have been tested, you are now ready to put them all together to form a directory synch solution as designed in your planning document.

Typically, a group of LDSU instances are run together from a master command file that is scheduled on the batch queue for the operating system where LDSU is running. In addition, a series of commands to initiate, retrieve, or wait for foreign directory exports or imports may be included (as needed) in these master command files.


HOME NEXT PREVIOUS

Digital Copyright © Digital Equipment Corporation 1998