Sun Java System Communications Services 6 2005Q4 Schema Migration Guide

commdirmig Non-Mandatory Options

Migration Online or in Preview Mode

You can choose whether to migrate the LDAP directory data directly (online) or run the utility in preview mode (write an audit of the migration to an LDIF-formatted file).

Use one of the following options to specify whether to use online or preview mode:

By default, commdirmig runs in preview mode (writes the migration audit to the LDIF file). It does not migrate the directory data online.

The default AuditLDIFFile is named commdirmig.audit.ldif.n

where n is a random number appended to the file name when the LDIF file is generated. The appended number makes the file name unique, which prevents the utility from overwriting any existing LDIF file. For example:


A new AuditLDIFFile is created whenever the maximum audit LDIF file size is exceeded. The file size is set by the -m LogMaxSize option.

The default paths for the AuditLDIFFile are as follows:






commdirmig -o

commdirmig -a /home/user/migration.audit.ldif

Domains Being Migrated

commdirmig can migrate a single domain, a list of domains, or all the domains in the LDAP directory. By default, commdirmig migrates all domains in the LDAP directory.

Use one of the following options to specify the domains to be migrated:


commdirmig -d,,

commdirmig -d *

commdirmig -f /home/user/domainnames.txt

Services to Add

By default, commdirmig migrates only the services it finds in the current directory. It does not add new services.

The -S option specifies whether to add new mail services, Calendar services, or both mail and Calendar services to the migrated directory.

Use the following arguments to add mail and Calendar services:


commdirmig -S mail -H

commdirmig -S mail, cal -H

Input File

-i InputFile directs commdirmig to read a user-created text file, InputFile, which contains a list of commdirmig options and arguments. commdirmig uses the information in the file to migrate the directory.

The command-line version of an option overrides the InputFile version of the same option. That is, if you enter an option in the command line and the same option exists in the InputFile, commdirmig uses the command-line option and ignores the option in the InputFile.

Formatting the Input File

The InputFile is a new-line separated ASCII text file. For each option to be specified in the InputFile, type the option letter, then a space, then the option arguments. Do not type a dash (-) before the option letters.

In the following example, an InputFile named commdirmig.input.txt specifies the Directory Server login ID and a file containing the password of the Directory Server user, the Directory Server host name and port number, and the OSI root and DC root:

D "cn=Directory Manager"
w /opt/SUNWcomm/passwd
X ldaphost
p 389
b "o=isp"
r "o=internet"

Uses of the Input File

If you use this option, you do not have to type all the options in the command line when you run the utility. Also, you can edit and reuse the InputFile, which makes it easier to run the utility multiple times. For example, you can do the following:


commdirmig -i /home/user/commdirmig.input.txt


Use the following options to specify logging:

Undo Migration

The following option allows you to undo (roll back) the changes made to the LDAP directory if an error occurs during the migration process:

If an error occurs during the migration, you can use the ldapmodify tool with the Undo log to roll back all the changes made by commdirmig. This step returns the LDAP directory to the state it was in before the migration began.

By default, commdirmig creates an Undo file.

By default, the UndoFile is named commdirmig.undo.ldif.


Use the following options to get help information and version: