Domino Server: Copy Database Commands

Of course there are multiple ways to create copies or replicas of databases either to other folders on the same server or to other servers ( especially when the servers are running in a cluster ).

I always use the following way and it´s working very fine:

First, you have to set an entry in the NOTES.INI of the server where you want to put the commands directly in the console:

Cluster_Admin_On=1

You also can set this NOTES.INI setting directly from the console with a
“set configuration Cluster_Admin_On=1” – you don´t have to restart the server, … ! This parameter is taken “on the fly”.

Now to the commands:

cl copy sourcedatabase targetdatabase
> Example: cl copy dev/demo.nsf prod/demo.nsf
> Creates a copy of the database dev/demo.nsf in the directory prod

cl copy sourcedatabase targetdatabase replica
> Example: cl copy Server1!!dev/demo.nsf Server2!!dev/demo.nsf replica
> Creates a full replica of the database dev/demo.nsf on Server 1 on Server 2

cl copy sourcedatabase targetdatabase template
> Example: cl copy Server1!!dev/demo.nsf Server2!!dev/demo.nsf template
> Only creates a template from the database dev/demo.nsf on Server 1 on Server 2 without any data

You also can use this command to create copies, replicas or templates within a program document:

Program name: nserver ( or server on Linux )
Command line: -c “cl copy Server1!!dev/demo.nsf Sever2!!dev/demo.nsf replica”

If you plan to run multiple “cl copy” commands you can pack them into a single text file ( in the example it´s called “command.txt” ):

cl copy demo/test1.nsf demo1/test1.nsf
cl copy demo/test2.nsf demo1/test2.nsf
cl copy demo/test3.nsf demo1/test3.nsf

and then you can create a program document where you run the commands included in the text file this way:

Program name: nserver ( or server on Linux )
Command line: -c “< path/command.txt”