layout | group | subgroup | title | menu_title | menu_node | menu_order | version | github_link | redirect_from |
---|---|---|---|---|---|---|---|---|---|
default |
migration |
D_Migrate using the data migration tool |
Migrate data |
Migrate data |
2 |
2.0 |
migration/migration-migrate-data.md |
/guides/v1.0/migration/migration-migrate-data.html |
-
Log in to Magento server as the file system owner.
-
Change to the Magento
/bin
directory or make sure it is added to your system PATH.
See the First steps section for more details.
To start migrating data, run:
bin/magento migrate:data [-r|--reset] {<path to config.xml>}
where:
-
[-r|--reset]
is an optional argument that starts migration from the beginning. You can use this argument for testing migration -
{<path to config.xml>}
is the absolute file system path toconfig.xml
; this argument is required
The Data Migration Tool saves its current progress as it runs. If errors or user intervention stop it from running, the Tool resumes progress at the last known good state.
To force the Data Migration Tool to run from the beginning, use the --reset
argument. In that case, we recommend you restore your Magento 2 database dump to prevent duplicating previously migrated data.
When you migrate data, the Data Migration Tool verifies that tables and fields are consistent between Magento 1 and Magento 2. If they are inconsistent, you will see an error message that lists the problematic tables and fields, for example:
Source fields are not mapped. Document: <document_name>. Fields: <field_name>
Possible reason for error: some database entities belong to Magento 1 extensions that do not exist in the Magento 2 database.
Below are the possible ways to handle these errors.
Visit Magento Marketplace{:target:"_blank"} to find the latest extension versions or contact your extension provider.
You may tell the Data Migration Tool to ignore the problematic entites.
To do that, add the <ignore>
tag to an entity in the map.xml
file, like this:
{% highlight xml %} sales_order_address_id {% endhighlight %}
Before ignoring entities, make sure you don't need the affected data in your Magento 2 store.
To know if the issues have been resolved successfully, run the Data Migration Tool again.