As you know, migration from Magento 1 to Magento 2 comprises of four key areas. These include Data migration, Extensions migration, Theme migration and migration of any customizations. In this post we’ll look at the data migration process. In this tutorial, I’ll be using the data migration tool provided by the Magento community, which is available at https://github.com/magento/data-migration-tool. The Magento versions used in this tutorial are:
Keep in mind that the Magento data migration process does not include the migration of:
Before you begin, you need to make sure that the following steps have been completed.
Before you start the data migration process, stop all Magento 1 Cron jobs.
During the migration process, do not:
1. Make any changes in the Magento 1 Admin area, except for order management (shipping, creating invoice, credit memos, etc.).
2. Alter any code.
3. Make changes in the Magento 2 Admin or store front.
You can carry out all regular operations in your Magento 1 store front though (taking and fulfilling orders, etc.).
The data migration should carried out in the following manner.
1. Migrate Settings (migrate all stores, websites, and system configuration like shipping, payment and tax settings, etc. According to Magento’s own documentation, it is best practice to migrate the settings first).
2. Migrate Data
3. Migrate Delta Changes (Incremental migration enables you to migrate only the changes made in Magento 1 since the last time data was migrated)
Step 1 – Download and configure the code migration tool
composer require magento/data-migration-tool:2.1.5
Step 2 – Configure the Magento 1 and Magento 2 databases.
Step 3 – Configure the “settings.xml” in order to migrate settings .
php bin/magento migrate:settings "vendor\magento\data-migration-tool\etc\ce-to-ce\1.9.2.4\config.xml" --reset
Step 4 – Configure “configure.xml” to migrate data.
Similarly, do the same acitivity for all data migration steps given below.
Once you’ve done that, launch the migration data tool from the Magento 2 root directory, by typing in the following command.
php bin/magento migrate:data "vendor\magento\data-migration-tool\etc\ce-to-ce\1.9.2.4\config.xml" --reset
If you see any of the following error messages, don’t worry, as they are simply referring to either data that’s missing or steps or part of the code which cannot be executed for some reason (the error and the reasons behind them are explained below, for each error).
1. [ERROR]: Source documents are not mapped: folio3_restorecancelled_order
This error simply means that these documents (i.e. the tables) cannot be migrated since they are not part of Magento’s core tables and they need to be ignored in the map.xml. To do that, just add the following code snippet inside the source <document_rules> tag in the map.xml file.
<ignore> <document>folio3_restorecancelled_order</document> </ignore>
2. [ERROR]: Source fields are not mapped.
Document: sales_flat_quote_item. Fields: orderspro_is_temporary?
This error indicates that these fields (i.e. columns) cannot be migrated, since they are not part of Magento’s core tables and as such, they need to be ignored in map.xml. To do that, just add the following code snippet inside the source’s <field_rules> tag in the map.xml file.
<ignore> <field>sales_flat_quote_item.orderspro_is_temporary</field> </ignore>
USA408 365 4638
1301 Shoreway Road, Suite 160,
Belmont, CA 94002
Whether you are a large enterprise looking to augment your teams with experts resources or an SME looking to scale your business or a startup looking to build something.
We are your digital growth partner.
Tel:
+1 408 365 4638
Support:
+1 (408) 512 1812
COMMENTS ()
Tweet