Move a Server
The following procedure moves a server to the new host new-server.example.com
.
The steps skip creation of system accounts, startup scripts, and registration as a Windows service:
-
Stop the server:
$ stop-ds
-
Renew the server certificate to account for the new hostname.
Skip this step if the server certificate is a wildcard certificate that is already valid for the new hostname.
The following command renews the server certificate generated with a deployment key:
$ dskeymgr \ create-tls-key-pair \ --deploymentKey $DEPLOYMENT_KEY \ --deploymentKeyPassword password \ --keyStoreFile /path/to/opendj/config/keystore \ --keyStorePassword:file /path/to/opendj/config/keystore.pin \ --hostname localhost \ --hostname new-server.example.com \ --subjectDn CN=DS,O=ForgeRock
For more command options, refer to dskeymgr. The default validity for the certificate is one year.
-
Find and replace the old hostname with the new hostname in the server’s configuration file,
config/config.ldif
.The following list includes configuration settings that may specify the server hostname:
-
ds-cfg-advertised-listen-address
-
ds-cfg-bootstrap-replication-server
-
ds-cfg-listen-address
-
ds-cfg-server-fqdn
-
ds-cfg-source-address
-
-
Move all files in the
/path/to/opendj
directory to the new server. -
Start the server:
$ start-ds
-
If the server you moved is referenced by others as a replication bootstrap server, update the replication bootstrap server configuration on those servers.