English Article · Software

Sitecore XM to XM Cloud Content Migration

Agenda:

  1. Introduction
  2. What does this tool do?
  3. What does the tool look like?
  4. What ZIP file contain?
  5. Prerequisites
  6. Sitecore XM Migration GUI
  7. Sitecore XM Migration Console

Sitecore has lots of customers who developed their solution based on classic Sitecore OnPrem which exists in the market for 2 decades. Also, Sitecore released the XM Cloud, a fully SaaS solution in July 2022.

Lots of customers continue to use the OnPrem solutions, new customers prefer to use the SaaS version and of course, some would like to switch to it, but it requires lots of effort. Sitecore just released to the public a brand-new XM to XM Cloud Content Migration tool that assists in minimizing the account’s barriers to migrating to Composable DXP.

What does this tool do?

It helps migrate customers’ data from the source of the XM OnPrem instance to the XM Cloud account. It migrates the content, media, and internal users (but not custom site data at this moment).

Currently, the tool supports Sitecore 10.1+, the 10.0 and 9.x support will be available in future releases.

The tool leveraging existing supported serialization and transfer tools, takes care of connecting to source and target accounts, installing dependencies, validating, do related actions, and cleanup.

Target scenarios1) Developer migrates data to dev environment, to enable the developing of a new solution.
2) Developer runs migration tool again for different content items, data from other sources, etc.
3) Developer repeats migration during development, to get the latest content (selectively migrate the latest content to dev).
Out of scopeDevOps merges the latest XM OnPrem content with the latest XM Cloud content (this is not the merge, diff or sync tool, it’s not supported).

What does the tool look like?

The tool is delivered via zip files that contain execution files. One of the targets is to possibly make it open source in the future. The current builds have two options:

  1. Download page https://developers.sitecore.com/downloads/xm-cloud (the latest version is 1.1.154).
  2. Direct link for GUI Sitecore.XM.Migration.GUI.v1.1.154.zip
  3. Direct link for CLI Sitecore.XM.Migration.Console.v1.1.154.zip

In general, it has the same functionality, the CLI is more for automation, and GUI for a better user experience.

Important note: the tool must be run from the same Server where Sitecore instance is installed. This might be improved in future releases. (Note from 2024: for the v2 it’s not relevant anymore).

Note: the current version is v1.1.154, it will evolve and the UI may be updated.

Note: the version v1.1.151 is obsoleted, please use the newer version.

What ZIP file contain?

  1. EXE file which runs the application.
  2. README.md – I strongly recommend reading it as it has lots of useful information.
  3. docs folder with the description of the appsettings.json file, dependencies, FAQ, and current known issues.

Prerequisites

  1. Sitecore XM OnPrem with some content, media, or users.
  2. A Fresh XM Cloud.

Sitecore XM Migration GUI

Run the XMMigrationGUI.exe

On the main screen, you have the choice to migrate Content, Media, or/and Users. Let’s check all options. The current Migrate source radio buttons are disabled and checked On-Premise by default, in future releases the tool going to support the Azure PaaS as well.

Click next and you’ll see the Source Configuration – Sitecore XM On Premise, please fill in the settings. You can check the settings in my example:

Click the Next button and fill in the Target Configuration – Sitecore XM Cloud settings. How to find one or another setting please follow the hints under each field:

Eventually, you should have settings similar to the following configuration:

When you click the Next button, you’ll see the Content Tree where you can choose which items to migrate:

At the bottom of the window, you can find the list of chosen items to migrate, when you choose an item – all the nested items will be migrated as well. Do not choose the Home item if you need to migrate only the specific tree nodes under it.

Let’s proceed to the next wizard window:

You’ll see this configuration if check the Users as a Migration type. Click the Connect button to choose at least one domain with users that you want to migrate, in my case it’s the maindepartment and sitecore that in total has 8 users. It will show only the domains that have at least 1 user with email. You can migrate (invite users to Sitecore Portal) only those who have email.

Click the Next button and configure the Users Migration Target Settings:

Click the Connect to Sitecore Cloud button and follow the instructions. A new browser window will be opened where you should log in as a Sitecore Portal User and confirm the code that you see in the Migration tool.
You should see the same code in the Migration tool.
Choose an organization where you would like to migrate users.

As the last step for users configuration, choose an environment where you would like to invite users under the chosen organization.

The users will be migrated under the specific organization and specific environment that you’ve chosen.

Click the Next button and check the summary just before the migration run:

Now, the tool is ready to migrate content, media, and users from specific domains. Click the Migrate button.
As a result of the migration, the tool automatically installed all the dependencies, etc, migrated content and media to XM Cloud, and also invited the users to the Sitecore Portal.
The migrated content is under the XM Cloud.
The invited users with the Pending status, each of the users received an invitation via email.
Example of the user invitation email.

If you need to run the application again, all the previous configurations will be saved in the appsettings.json file and you don’t need to fill in all the settings again. Also, this file has some configuration that you don’t need to touch, for example, endpoints to the Sitecore Portal, but there is an ability for you just in case any of the Sitecore endpoints are updated.

Also, it has additional settings related to which users to retrieve from the Source Sitecore instance, such as:

“AllowApproved”: true – retrieves only approved users
“AllowLockedOut”: false – do not retrieve locked-out users.

The root folder of the tool contains the logs folder, each time you run the tool, you’ll have the detailed logs during the run:

Sitecore XM Migration Console

The Console tool in terms of functionality is the same and can be used for scripting/automation. Navigate to the folder of the console app and type the .\XMMigration.exe --help command, you’ll see a bunch of options:

Important: to have the same settings as you made in the GUI version you can just copy and replace the appsettings,json file or adjust it manually.

Migrate content .\XMMigration.exe --migrate-source onpremise --migrate-content

To retrieve the list of domains use the next command: .\XMMigration.exe --retrieve-domains

To invite users from the sitecore and maindepartment domains: .\XMMigration.exe --migrate-userdomains sitecore,maindepartment

In this case, you might need to login to the Sitecore Portal via a browser (you’ll see a new browser tab).

Enjoy the tool and let me know if you have any questions or suggestions, your feedback is valuable! =)

Also, you contact us on the community Slack #xm-cloud channel.

* Future features discussed in this document are subject to change.

4 thoughts on “Sitecore XM to XM Cloud Content Migration

  1. Good article to understand step by step to migrate content and other details to XM cloud. Is it possible to migrate content , media and users from traditional Sitecore application (either SXA or non SXA sites) to target XM cloud environment (headless)

    Like

    1. Thanks Ravikumar, yes, it’s possible to migrate the mentioned content from traditional Sitecore (either SXA or non SXA sites) to the target XM Cloud.

      Like

Leave a reply to smitbmx Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.