/opt/redhat-ds/slapd-instancename/db), migration will not copy these databases, but will use the directly. This means that if you run migration, you may not be able to go back to the old version. Migration will not remove or destroy the data, but may change the format in such a way that you cannot use the older version of the Directory Server. Therefore, make a database backup using db2bak and an LDIF dump using db2ldif of the databases to make sure everything can be recovered.
/var/lib/dirsrv/slapd-instance_name/db, but will instead assume that the databases should be in their non-standard location and configure the new server to use the databases in the old location.
migrate-ds-admin.pl, has flexible options that allow a variety of different migration scenarios, including migrating between different different platforms. This options are listed in Table 5.1, “migrate-ds-admin Options”.
oldsroot, which gives the directory path to the old Directory Server. There is also one required argument, General.ConfigDirectoryAdminPwd, which gives the password of the directory administrator for the old Directory Server. If either of these are not supplied, the migration script will exit.
/usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
migrate-ds-admin tool is in the /usr/sbin directory.
| Option | Alternate Options | Description |
|---|---|---|
| General.ConfigDirectoryAdminPwd=password |
Required. This is the password for the configuration directory administrator of the old Directory Server (the default username is admin).
| |
| --oldsroot | -o |
Required. This is the path to the server root directory in the old 7.1 Directory Server installation. The default path in 7.1 servers is /opt/redhat-ds/.
|
| --actualsroot | -a |
This is used for migrating between two machines to specify the real path to the current server root directory in the old 7.1 Directory Server installation if that directory is mounted on a networked drive or tarballed and moved to a relative directory. In that case, the oldsroot parameter sets the directory from which the migration is run (such as machine_new:/migrate/opt/redhat-ds/), while the actualsroot parameter sets the server root, (/opt/redhat-ds/).
|
| --instance | -i | This parameter specifies a specific instance to migrate. This parameter can be used multiple time to migrate several instances simultaneously. By default, the migration script migrates all Directory Server instances on the machine. |
| --file=name | -f name |
This sets the path and name of the .inf file provided with the migration script. The only parameter is the General.ConfigDirectoryAdminPwd parameter, which is the configuration directory administrator's password. Any other configuration setting is ignored by the migration script.
|
| --cross | -c or -x | This parameter is used when the Directory Server is being migrated from one machine to another with a different architecture. For cross-platform migrations, only certain data are migrated. This migration action takes database information exported to LDIF and imports into the new 8.2 databases. Changelog information is not migrated. If a supplier or hub is migrated, then all its replicas must be reinitialized. |
| --debug | -d[dddd] |
This parameter turns on debugging information. For the -d flag, increasing the number of d's increases the debug level.
|
| --logfile name | -l |
This parameter specifies a log file to which to write the output. If this is not set, then the migration information is written to a temporary file, named
/tmp/migrateXXXXX.log.
To disable logging, set
/dev/null as the logfile.
|
migrate-ds-admin.pl allows the password parameter to be provided on the command line, similar to the setup-ds-admin.pl script. The arguments set the section, parameter, and value of .inf parameters in the following form:
section.parameter=valueConfigDirectoryAdminPwd):
/usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
.inf file with the migration script that gives the administrator's password:
/usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds --file=/export/example.inf
.inf would have the following two lines:
[General]
ConfigDirectoryAdminPwd=password--oldsroot. Any other argument passed in the command line or listed in an inf file, such as those used with the setup-ds-admin/pl script, is ignored. The Directory Server configuration parameters are only taken from the old instance. It is not possible to change the configuration settings, such as the hostname or port, using the migration script.
10presence.ldif, from the schema/ directory for the old instance.
/opt/redhat-ds/slapd-serverID/config directory. Other important configuration files for the Admin Server and for shared configuration are in /opt/redhat-ds/admin-serv/config and /opt/redhat-ds/shared/config. Make a backup of all of these files in a secure location.
o=NetscapeRoot replicated between the two master servers, server1 and server2. By default, writes made through server2's Directory Server Console are written to server1, then replicated over. Modify the Directory Server Console on the second server (server2) so that it writes its own Console instance instead of server1's.
adm.conf file for the Admin Server to reflect server2 Directory Servers values:
ldapurl: ldap://server2.example.com:389/o=NetscapeRoot
dse.ldif for the Directory Server to reflect server2 Directory Server's values:
vimserverRoot/slapd-serverID/config/dse.ldif nsslapd-pluginarg0: ldap:///server2.example.com:389/o=NetscapeRoot
server2 by editing its dse.ldif file and setting the nsslapd-pluginEnabled value to off.
vimserverRoot/slapd-serverID/config/dse.ldif dn: cn=Pass Through Authentication,cn=plugins,cn=config nsslapd-pluginEnabled:off
/slapd-serverID/config/schema/ directory. This can be done by comparing the list of schema files in the old schema directory to the list in the new /etc/dirsrv/schema directory. Deprecated schema files include:
/usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
instance with the migrate-ds-admin tool. For example, to migrate the Directory Server instance named example and example3, but not example2, the migration command would be as follows:
/usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds --instance example --instance example3 General.ConfigDirectoryAdminPwd=password
migrate-ds-admin tool is in the /usr/sbin directory.
setup-ds-admin.pl before running the migration script.
root.
# /usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds/ General.ConfigDirectoryAdminPwd=password
/opt/redhat-ds/ is the directory where the old Directory Server is installed.
passwordMinLength for a global password policy, are not migrated.
[...] - import userRoot: WARNING: Skipping duplicate entry "cn=uid\3Dtuser1\2Cou\3DOU0\2Co\3DO0,ou=People,dc=example,dc=com" found at line 35 of file "/opt/redhat-ds/slapd-ID/db/example.ldif"
remove-ds-admin.pl to remove the newly-migrated server, and run the migration script again.
--actualsroot and --cross parameters with migrate-ds-admin.pl, as described in Section 5.2.5, “Migrating a Directory Server from One Machine to Another” and Section 5.2.6, “Migrating a Directory Server from One Platform to Another”.
migrate-ds-admin tool is in the /usr/sbin directory.
389.
root.
setup-ds-admin.pl before running the migration script.
# /usr/sbin/migrate-ds-admin.pl --oldsroot /opt/redhat-ds/ General.ConfigDirectoryAdminPwd=password
/opt/redhat-ds/ is the directory where the old Directory Server is installed.
passwordMinLength for a global password policy, are not migrated.
migrate-ds-admin) with options specifying the physical, network-accessible old server root directory (oldsroot), such as tarball or network drive, and specifying the actual directory name of the server root on the old machine (actualsroot), such as /opt/redhat-ds. In this case, actualsroot names the original absolute installation directory, which oldsroot gives the path to access that directory.
ldap.example.com to ldap_old.example.com), then give the new machine the original name of the old machine (ldap.example.com). Because of the large number of configuration issues based on the Directory Server's hostname — including the Console, replication, TLS/SSL, and Kerberos — it is extremely difficult to rename the server with the migration script. Red Hat strongly recommends that you do not attempt to change the Directory Server hostname.
migrate-ds-admin tool is in the /usr/sbin directory.
server1 to server2, using an NFS-mounted directory:
# /usr/sbin/migrate-ds-admin.pl --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
oldsroot can also specify a local directory on the target machine that was created from a tarball. In that case, create a tarball of your old server root directory, and untar it on the target machine. In this example, a tarball was created of /opt/redhat-ds on the source machine, and it was untarred under /migration on the target machine:
# /usr/sbin/migrate-ds-admin.pl --oldsroot /migration/opt/redhat-ds --actualsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
migrate-ds-admin command automatically migrates every Directory Server instance configured. As with migrating Directory Server on the same machine, using the instance parameter allows you to set the specific instance to migrate. For example, this command migrated a Directory Server instance named example:
# /usr/sbin/migrate-ds-admin.pl --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds --instance example General.ConfigDirectoryAdminPwd=password
root. Specify the current physical location of the Directory Server with the oldsroot parameter and the location on the old machine with the actualsroot parameter.
setup-ds-admin.pl before running the migration script.
# /usr/sbin/migrate-ds-admin.pl --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
passwordMinLength for a global password policy, are not migrated.
actualsroot and oldsroot parameters to migrate across machines and the cross parameter to signal that the migration is cross-platform.
migrate-ds-admin tool is in the /usr/sbin directory.
# /usr/sbin/migrate-ds-admin.pl --cross --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
migrate-ds-admin command automatically migrates every Directory Server instance configured. As with migrating Directory Server on the same machine, using the instance parameter allows you to set the specific instance to migrate. For example, this command migrated a Directory Server instance named example:
/usr/sbin/migrate-ds-admin.pl --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds --instance example General.ConfigDirectoryAdminPwd=password
.ldif appended. For example:
cd /opt/redhat-ds/slapd-instance./db2ldif -n userRoot -a /opt/redhat-ds/slapd-instance/db/userRoot.ldif ./db2ldif -n NetscapeRoot -a /opt/redhat-ds/slapd-instance/db/NetscapeRoot.ldif
chmod 444 /opt/redhat-ds/slapd-instance/db/userRoot.ldif chmod 444 /opt/redhat-ds/slapd-instance/db/NetscapeRoot.ldif
root. Specify the current physical location of the Directory Server with the oldsroot parameter and the location on the old machine with the actualsroot parameter.
setup-ds-admin.pl before running the migration script.
/usr/sbin/migrate-ds-admin.pl --cross --oldsroot server2:/migration/opt/redhat-ds --actualsroot /opt/redhat-ds General.ConfigDirectoryAdminPwd=password
passwordMinLength for a global password policy, are not migrated.