1

An exception was printed to the console during migration. Please tell me what you mean.

My migration procedure is as follows.

1.Installed Magento version 2.2.6.

2.The application and database were backed up so that the data could be restored immediately after installation.

3.installing extensions

4.Installing the Magento 2 Data Migration Tool

5.You have edited the migration settings file.

<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
 * Copyright © 2013-2017 Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */
-->
<config xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="../../config.xsd">
    <steps mode="settings">
        <step title="Settings Step">
            <integrity>Migration\Step\Settings\Integrity</integrity>
            <data>Migration\Step\Settings\Data</data>
        </step>
        <step title="Stores Step">
            <integrity>Migration\Step\Stores\Integrity</integrity>
            <data>Migration\Step\Stores\Data</data>
            <volume>Migration\Step\Stores\Volume</volume>
        </step>
    </steps>
    <steps mode="data">
        <step title="Data Integrity Step">
            <integrity>Migration\Step\DataIntegrity\Integrity</integrity>
        </step>
        <step title="EAV Step">
            <integrity>Migration\Step\Eav\Integrity</integrity>
            <data>Migration\Step\Eav\Data</data>
            <volume>Migration\Step\Eav\Volume</volume>
        </step>
        <step title="Customer Attributes Step">
            <integrity>Migration\Step\Customer\Integrity</integrity>
            <data>Migration\Step\Customer\Data</data>
            <volume>Migration\Step\Customer\Volume</volume>
        </step>
        <step title="Map Step">
            <integrity>Migration\Step\Map\Integrity</integrity>
            <data>Migration\Step\Map\Data</data>
            <volume>Migration\Step\Map\Volume</volume>
        </step>
        <step title="Url Rewrite Step">
            <integrity>Migration\Step\UrlRewrite\Version191to2000</integrity>
            <data>Migration\Step\UrlRewrite\Version191to2000</data>
            <volume>Migration\Step\UrlRewrite\Version191to2000</volume>
        </step>
        <step title="Log Step">
            <integrity>Migration\Step\Log\Integrity</integrity>
            <data>Migration\Step\Log\Data</data>
            <volume>Migration\Step\Log\Volume</volume>
        </step>
        <step title="Ratings Step">
            <integrity>Migration\Step\Ratings\Integrity</integrity>
            <data>Migration\Step\Ratings\Data</data>
            <volume>Migration\Step\Ratings\Volume</volume>
        </step>
        <step title="ConfigurablePrices step">
            <integrity>Migration\Step\ConfigurablePrices\Integrity</integrity>
            <data>Migration\Step\ConfigurablePrices\Data</data>
            <volume>Migration\Step\ConfigurablePrices\Volume</volume>
        </step>
        <step title="OrderGrids Step">
            <integrity>Migration\Step\OrderGrids\Integrity</integrity>
            <data>Migration\Step\OrderGrids\Data</data>
            <volume>Migration\Step\OrderGrids\Volume</volume>
        </step>
        <step title="Tier Price Step">
            <integrity>Migration\Step\TierPrice\Integrity</integrity>
            <data>Migration\Step\TierPrice\Data</data>
            <volume>Migration\Step\TierPrice\Volume</volume>
        </step>
        <step title="SalesIncrement Step">
            <integrity>Migration\Step\SalesIncrement\Integrity</integrity>
            <data>Migration\Step\SalesIncrement\Data</data>
            <volume>Migration\Step\SalesIncrement\Volume</volume>
        </step>
        <step title="PostProcessing Step">
            <data>Migration\Step\PostProcessing\Data</data>
        </step>
    </steps>
    <steps mode="delta">
        <step title="Customer Attributes Step">
            <delta>Migration\Step\Customer\Delta</delta>
            <volume>Migration\Step\Customer\Volume</volume>
        </step>
        <step title="Map Step">
            <delta>Migration\Step\Map\Delta</delta>
            <volume>Migration\Step\Map\Volume</volume>
        </step>
        <step title="Log Step">
            <delta>Migration\Step\Log\Delta</delta>
            <volume>Migration\Step\Log\Volume</volume>
        </step>
        <step title="OrderGrids Step">
            <delta>Migration\Step\OrderGrids\Delta</delta>
            <volume>Migration\Step\OrderGrids\Volume</volume>
        </step>
        <step title="SalesIncrement Step">
            <delta>Migration\Step\SalesIncrement\Delta</delta>
            <volume>Migration\Step\SalesIncrement\Volume</volume>
        </step>
    </steps>
    <source>
        <database host="localhost" name="m1_db" user="magento" password="a201262907/002/0" />
    </source>
    <destination>
        <database host="localhost" name="m2_db" user="magento" password="a201262907/002/0" />
    </destination>
    <options>
        <crypt_key>5e9bf8abe895328d0853754072a3328f</crypt_key>
        <map_file>etc/opensource-to-opensource/1.9.2.1/map.xml</map_file>
        <eav_map_file>etc/opensource-to-opensource/map-eav.xml</eav_map_file>
        <eav_document_groups_file>etc/opensource-to-opensource/eav-document-groups.xml</eav_document_groups_file>
        <eav_attribute_groups_file>etc/opensource-to-opensource/eav-attribute-groups.xml</eav_attribute_groups_file>
        <log_map_file>etc/opensource-to-opensource/map-log.xml</log_map_file>
        <log_document_groups_file>etc/opensource-to-opensource/log-document-groups.xml</log_document_groups_file>
        <settings_map_file>etc/opensource-to-opensource/settings.xml</settings_map_file>
        <customer_map_file>etc/opensource-to-opensource/map-customer.xml</customer_map_file>
        <customer_document_groups_file>etc/opensource-to-opensource/customer-document-groups.xml</customer_document_groups_file>
        <customer_attribute_groups_file>etc/opensource-to-opensource/customer-attribute-groups.xml</customer_attribute_groups_file>
        <delta_document_groups_file>etc/opensource-to-opensource/deltalog.xml</delta_document_groups_file>
        <order_grids_document_groups_file>etc/opensource-to-opensource/order-grids-document-groups.xml</order_grids_document_groups_file>
        <map_document_groups>etc/opensource-to-opensource/map-document-groups.xml</map_document_groups>
        <class_map>etc/opensource-to-opensource/class-map.xml</class_map>
        <tier_price_map_file>etc/opensource-to-opensource/map-tier-price.xml</tier_price_map_file>
        <stores_map_file>etc/opensource-to-opensource/map-stores.xml</stores_map_file>
        <!--
        In case bulk_size=0 it will be auto-detected for every document.
        -->
        <bulk_size>0</bulk_size>
        <!--
        Set direct_document_copy = 1 for better performance.
        NOTE: 'source' and 'destination' databases MUST be placed on the same MySQL instance
        and 'destination' user MUST be granted with 'SELECT' permissions on 'source' database
         -->
        <direct_document_copy>0</direct_document_copy>
        <source_prefix />
        <dest_prefix />
        <auto_resolve_urlrewrite_duplicates>0</auto_resolve_urlrewrite_duplicates>
        <log_file>migration.log</log_file>
        <progress_bar_format>%percent%% [%bar%] Remaining Time: %remaining%</progress_bar_format>
        <upgrade_customer_password_hash>1</upgrade_customer_password_hash>
        <edition_migrate>opensource-to-opensource</edition_migrate>
        <edition_number>1.9.2.1</edition_number>
        <init_statements_source>SET NAMES utf8;</init_statements_source>
        <init_statements_destination>SET NAMES utf8;</init_statements_destination>
    </options>
</config>

6.I confirmed it.

php bin/magento migrate:settings -r /var/www/html/document_root/vendor/magento/data-migration-tool/etc/opensource-to-opensource/1.9.2.1/config.xml

7.Initial migration performed.

php bin/magento migrate:data -r -a /var/www/html/document_root/vendor/magento/data-migration-tool/etc/opensource-to-opensource/1.9.2.1/config.xml -vvv

8.Naturally, some problems were printed to the console.

9.After fixing the problem, the database was returned to a clean state and repeatedly validated.

10.Fixed common problems, but only the following exceptions were not fixed:.

Reset the current position of migration to start from the beginning

[2019-07-31 06:13:55][INFO][mode: data][stage: integrity check][step: Data Integrity Step]: started
[2019-07-31 06:13:56][INFO][mode: data][stage: integrity check][step: EAV Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:56][INFO][mode: data][stage: integrity check][step: Customer Attributes Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:56][INFO][mode: data][stage: integrity check][step: Map Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: Url Rewrite Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: Log Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: Ratings Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: ConfigurablePrices step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: OrderGrids Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: Tier Price Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: integrity check][step: SalesIncrement Step]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:13:59][INFO][mode: data][stage: setup triggers][step: Stage]: started
100% [============================] Remaining Time: < 1 sec
[2019-07-31 06:14:00][INFO][mode: data][stage: data migration][step: EAV Step]: started
71% [====================>-------] Remaining Time: < 1 sec

  [Exception]                                                                                                                             
  Notice: Undefined offset: 151 in /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Step/Eav/Data.php on line 813  


Exception trace:
 () at /var/www/html/document_root/vendor/magento/framework/App/ErrorHandler.php:61
 Magento\Framework\App\ErrorHandler->handler() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Step/Eav/Data.php:813
 Migration\Step\Eav\Data->migrateAttributesExtended() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Step/Eav/Data.php:192
 Migration\Step\Eav\Data->perform() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Mode/AbstractMode.php:79
 Migration\Mode\AbstractMode->runStage() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Mode/Data.php:119
 Migration\Mode\Data->runData() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Mode/Data.php:69
 Migration\Mode\Data->run() at /var/www/html/document_root/vendor/magento/data-migration-tool/src/Migration/Console/MigrateDataCommand.php:51
 Migration\Console\MigrateDataCommand->execute() at /var/www/html/document_root/vendor/symfony/console/Command/Command.php:245
 Symfony\Component\Console\Command\Command->run() at /var/www/html/document_root/vendor/symfony/console/Application.php:835
 Symfony\Component\Console\Application->doRunCommand() at /var/www/html/document_root/vendor/symfony/console/Application.php:185
 Symfony\Component\Console\Application->doRun() at /var/www/html/document_root/vendor/magento/framework/Console/Cli.php:104
 Magento\Framework\Console\Cli->doRun() at /var/www/html/document_root/vendor/symfony/console/Application.php:117
 Symfony\Component\Console\Application->run() at /var/www/html/document_root/bin/magento:23

migrate:data [-r|--reset] [-a|--auto] [--] <config>

What's the matter?

0

Install Data Migration Tool

1) Check your Magento 2 version :- sudo php bin/magento --version

2) Install Data Migration Tool from repo.magento.com :-

composer config repositories.magento composer https://repo.magento.com                                   
composer require magento/data-migration-tool:<magento_version>

3) Configure Magento 2 Data Migration Tool :-

    1 The above file will contain configuration and scripts for migrating from Magento 1 Open Source platform to Magento 2 Open          Source platform.
         <your Magento 2 install dir>/vendor/magento/data-migration-tool/etc/opensource-to-opensource

    2 The above file will contain configuration and scripts for migrating from Magento 1 Open Source platform to Magento 2 Commerce.
         <your Magento 2 install dir>/vendor/magento/data-migration-tool/etc/opensource-to-commerce

    3 The above file will contain configuration and scripts for migrating from Magento 1 Commerce to Magento 2 Commerce.
         <your Magento 2 install dir>/vendor/magento/data-migration-tool/etc/commerce-to-commerce

4) Configuring the migration :-

    1 Change to the following directory :-
      <your Magento 2 install dir>/vendor/magento/data-migration-tool/etc/<migration edition>/<ce or version>

    2 Rename config.xml.dist to config.xml 
      cp config.xml.dist config.xml

    3 Open config.xml in a text editor.

    4 Specify the following at minimum:

            <database host="localhost" name="Magento1-DB-name" user="DB-username" password="DB-password"/>

            </source>

            <destination>

            <database host="localhost" name="Magento2-DB-name" user="DB-username" password="DB-password"/>

            </destination>

            <options>

            <crypt_key>Magento1-Encrypted-Key</crypt_key>

            </options>

5) Migrate settings :-

        php bin/magento migrate:settings --reset vendor/magento/data-migration-tool/etc/<edition-to-edition>/<version>/config.xml

6) Migrate Data :-

        php bin/magento migrate:data --reset vendor/magento/data-migration-tool/etc/<edition-to-edition>/<version>/config.xml

        php bin/magento migrate:data --auto vendor/magento/data-migration-tool/etc/<edition-to-edition>/<version>/config.xml

7) Migrate Delta :-

        php bin/magento migrate:delta --reset vendor/magento/data-migration-tool/etc/<edition-to-edition>/<version>/config.xml

        php bin/magento migrate:delta --auto vendor/magento/data-migration-tool/etc/<edition-to-edition>/<version>/config.xml

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.