As part of Marklogic 6.0 release, a new Marklogic Supported tool named Marklogic Content Pump (mlcp) let you copy/move/migrate/shift data from one Marklogic server to another. If you're using Marklogic below version 6.0, the way to do this is to use XQsync to import/export Marklogic documents and metadata.
To copy date between servers, you can use the mlcp copy command. Alternatively, you can use mlcp export command with an output type of archive (that includes content and metadata) to create a database archive. Then use the mlcp import command to copy/import the archive to another database to complete migrating the database contents.
Use mlcp only if you have Marklogic 6.0 or above. If not, use XQsync instead.
Copy Marklogic Data
To copy from one Marklogic server directly to another, e.g.,
./mlcp.sh copy -help
Export Marklogic Data
To export Marklogic Archive from one server,
./mlcp.sh export -help
 XDBC server and port on which XDBC server is running to export data from.
 mlcp transparently splits work among multiple threads on a local/single machine.
 Limit the dump to /content/cq/ directory
Import Marklogic Data
To import a Marklogic Archive into another Marklogic server, e.g.,
./mlcp.sh import -help