April 1, 2020
Estimated Post Reading Time ~

How to use vlt tool to copy data from one CRX to other CRX

Use Case Some time you want to migrate repository from one instance to another instance (Because of non repairable corruption in current repository). If your repository size is big, Package manager is not a viable option (As you end up creating a lot of packages)


Assumption You have basic knowledge about CQ structure and CRX. You are using crx2.2 or higher. Path of copy could differ if you are using older version of CRX.


Here are different options:

1) Use package manager

Pros: Very simple to create and do not require command like knowledge
Cons: Not suitable for Big packages. Slow some time2) Use VLT (We are explaining how to use this in this article)

Pros: Faster than package manager. Do not consume package space like package manager.
Cons: Slow I/O3) Use Tool based on VLT like Recap http://adamcin.net/net.adamcin.recap/

Pros: VLT rcp UI easy to see status and administer. Do not require command like knowledge.
Cons: Slow I/O because it uses VLT under the hood.4) Use Tool based on other transfer protocol like Grabit https://github.com/TWCable/grabbit

Pros: Faster than VLT
Cons: Not Adobe supported. Need more dependency to set up.


Step 1: Make sure that you have vlt set up properly. More detail can be found here. In the end you can use vlt --version command to check if vlt is installed.






Step 2: Use following command to Migrate data between CRX


vlt rcp -r http://<login>:<password>@<source-host>:<port>/crx/-/jcr:root/<Source-Path> http://<login>:<password>@<destination-host>:<port>/crx/-/jcr:root/


Note
1) While you are migrating data from one CQ to another CQ, make sure that you stop launchpad application from <host>:<port>/admin (This will make sure that unnecessary workflows are not getting triggered during migration). If this is not possible make sure that you disable DAM related workflow by going to http://<host>:<port>/libs/cq/workflow/content/console.html and then launcher. Don't forget to re enable them after the copy and make sure that no DAM activities are going on during that time on target instance.




2) Note that copying user and groups does not mean all ACL are also copied. ACL are stored under /content node. In general you need to migrate following stuff (Plus if you have some thing else custom)
-- /content/<Your-site>
-- /apps/<Your-application>
-- /var/dam/<your-asset>
-- /content/dam/<your-asset>
-- /etc/design/<your-design>
-- /etc/tags/<your-tags>
-- /etc/workflow/<your-custom-stuff>
-- /etc/replication/<your-custom-replication>


Important Note: At any point of time (Even after Migration). You have to make sure that /content/dam and /var/dam are sync. After migration go to http://<host>:<port>/etc/dam/healthchecker.html and make sure that they are in sync by clicking check binaries (List entries missing in /var/dam) and check Asset (List entries missing in /content/dam). You might also do small test before you do big migration to make sure that all renditions are getting migrated fine.


If you want to process all asset again then just migrate /var/dam in batches (As Asset synchronization using workflow could be expensive) and enable launchpad or all workflows. In order to migrate Asset in baches you can use sleep between two rsync. Make sure that you monitor logs of target system for any OOM error or any issue.


You can have script to do above with all the path (So that you can re use them in future)


If do not have Login can download Recap from Here


By aem4beginner

No comments:

Post a Comment

If you have any doubts or questions, please let us know.