Take on topic of Data migration from Magento 1.x to Magento 2.0. Available tools, valuable insights and gothas. YT video is here - https://www.youtube.com/watch?v=UBK1rNjMauo
from one or more old systems, to a new system or systems. ▸ Data migration is typically part of a larger programme ▸ “Big bang” and “trickle” migrations WHAT IS DATA MIGRATION? MARCIN SZTERLING REDBOX DIGITAL @php4u
the data? ▸ If just part, which parts? - based on creation date? based on status of product, customer? or some combination of criteria? ▸ If we choose to bring over data on or after a certain date, which should it be - last 3 months, last 6 months, last year?...should it be all the data? ▸ Should we clean data at source or destination? BEFORE ALL STARTS MARCIN SZTERLING REDBOX DIGITAL @php4u
DAY TASK ▸ CE -> CE, CE -> EE, EE -> EE ▸ There is no silver-bullet solution ▸ There will be issues with source data ▸ There will be issues with migrated data ▸ Amount of data matters ▸ Reserve time for it and prepare for battle! ▸ http://alankent.me/2015/01/31/ magento-1-to-2-migration-tool-plans/ MARCIN SZTERLING REDBOX DIGITAL @php4u
(WHAT THE HELL IS EAV??) ▸ Products ▸ Categories (and its products relations) ▸ Customers ▸ Orders ▸ Configurations ▸ CMS elements ▸ Websites, Store groups, Stores ▸ Media assets for Products, Categories, CMS MARCIN SZTERLING REDBOX DIGITAL @php4u
can be deleted ▸ Tables can be renamed ▸ New tables can exist in Magento 2 but not in Magento 1 ▸ Table columns can be deleted ▸ Table columns can be renamed ▸ New table columns can exist in Magento 2 but not in Magento 1 MARCIN SZTERLING REDBOX DIGITAL @php4u
be changed to match Magento 2 new classes namespaces (models) ▸ Values must be nulled even if are empty ▸ Names must be prefixed to avoid naming issues WHAT EXACTLY HAS CHANGED FROM M1 TO M2? MARCIN SZTERLING REDBOX DIGITAL @php4u
data migration (1.0.4) https://github.com/ubertheme/module-ubdatamigration ▸ Magento data migration tool (2.0.2) https://github.com/magento/data-migration-tool ▸ CSV based import ▸ Custom own written solution (API?) ▸ https://github.com/SchumacherFM/Magento2-Data- Migration MARCIN SZTERLING REDBOX DIGITAL @php4u
tool ▸ Not secured at all so you must not use it on production unless secured ▸ Almost zero configuration required ▸ Slow and dependant on server settings ▸ Supports delta changes and can be migrated on top of existing data ▸ Does the job! ▸ More info how to use it here https://github.com/ubertheme/module-ubdatamigration/blob/master/ README.md MARCIN SZTERLING REDBOX DIGITAL @php4u
(2.0.2) for both EE and CE ▸ Preconfigured for all magento versions and editions ▸ Works with magento sample data (!) ▸ Supports delta changes ▸ Cannot be migrated on top of existing data ▸ Requires “perfect” source data integrity (ex. eav_entity_type) ▸ Blazing fast (with exceptions) ▸ xml based configuration - which can be stored in VCS, can have multiple profiles ▸ No way to specify database connection details in CLI ▸ Very flexible configuration to adjust to needs, easy to extend ▸ Progress bar with estimated time per task (but not for overall task) ▸ No automated data verification after import MARCIN SZTERLING REDBOX DIGITAL @php4u
types of run modes in Migration/Console Data, Delta, Settings ▸ Data is read, transformed and then saved in batches ▸ CPU and memory heavy MARCIN SZTERLING REDBOX DIGITAL @php4u
your old Magento database ▸ Destination - your new Magento 2 database ▸ Document - mysql table ▸ Field - mysql column ▸ https://github.com/magento/data-migration-tool/blob/ master/etc/ce-to-ee/map-eav.xml.dist MARCIN SZTERLING REDBOX DIGITAL @php4u
Source fields not mapped. Document: sales_flat_order. Fields: field1, field2 ▸ [ERROR]: Destination fields not mapped. Document: customer_entity. Fields: field1, field2 ▸ Interesting script - http://oyenetwork.com/articles/data-migration- to-magento2-case-study/ ▸ Problem with EAV relationships after migration ▸ Error messages are not detailed enough (Mismatch of entities in the document) MARCIN SZTERLING REDBOX DIGITAL @php4u
per task group ▸ Try with smaller data samples - it is easier to debug it ▸ Use -vvv for extended debugging ▸ Use -r to restart process ▸ Source and Destination resource classes are disabling foreign keys check ▸ Password rehash is performance killer ▸ Create your own steps, create your own handlers ▸ Some of the attributes might be required in M2 and are not in M1 (telephone) MARCIN SZTERLING REDBOX DIGITAL @php4u
task - copy data on top of clean Magento 2 installation ▸ Ideally try to have two databases on same server ▸ Magento 1 instance can be live during migration ▸ Docs - http://devdocs.magento.com/guides/v2.0/migration/bk-migration- guide.html ▸ Logging can be extended ▸ The versions of the Data Migration Tool and your Magento software must exactly match. For example, if you’re using version 2.0.2 of the Magento software, you must use version 2.0.2 of the Data Migration Tool. MARCIN SZTERLING REDBOX DIGITAL @php4u
▸ Do many mysql dumps in the process, so data can be reverted to previous state ▸ DROP DATABASE …, CREATE DATABASE … ▸ Keep your files separate from core data-migration files MARCIN SZTERLING REDBOX DIGITAL @php4u