Data migration is not working correctly

 Hello,
I have migrated my magento 1.6x DB with Magento 2.1.3 using UB Data Migration older version, now i’m migration my magento 1.6x DB to Magento 2.1.3 again(in existing DB).
Migration get complete successfully but, here i’m facing the following issue 

  1. it’s creating additional category named(migrated) and also creating additional website and stores
  2. The visibility of all configurable product changed to “Not visible” and their child product visibility changed to “catalog, search”, both are incorrect.
  3. All products  get disabled.
  4. Because of these following issues products are not visible on frontend.

Please let me know if i’m doing any worng.
Thank you.

22 answers

Profile photo of Mall Staff 184060.00 $tone August 21, 2017
Public

Hi there,

I have migrated my magento 1.6x DB with Magento 2.1.3 using UB Data Migration older version, 

May I know what version of our tool you used in the first time? We have an outdated script on Github which we no longer use. 

  1. it’s creating additional category named(migrated) and also creating additional website and stores

Yes, that is right. It seems you have used ver2.x of our tool in your first migration. Please note that, our v2.x and v3.x has difference process and this is the root of issue.

The visibility of all configurable product changed to “Not visible” and their child product visibility changed to “catalog, search”, both are incorrect.

This is a strange issue. Our tool doesn’t make any change to your product’s setting on visibility attribute. Kindly re-compare with your products in Magento 1 to see the original setting of such product in M1.

Please let me know if i’m doing any worng.

With our latest tool version 3.0.9, you should consider re-migrating from the ground up in a new fresh Magento 2 instance.
Regards,
Mall.

#1
Profile photo of Stephen Kidwell 210.00 $tone August 22, 2017
Public

May I know what version of our tool you used in the first time? We have an outdated script on Github which we no longer use. 

I have used 2.0.4 pro version for migration earlier.
 
More issues found:-

  1. During the migration, product url get changed to {{base_url}}.html.html , there is extra “.html” appending in product url

 
Query:- 
Case 1:- If i migrate the magento 1.6x in fresh magento 2.x,
               a) How can i migrate the core_config_data from magento 1.6x to fresh magento 2.x
Case 2:-  I mentioned in my previous question that i have migrated my data using 2.0.4 pro version, now i need to update the data in existing M2 DB from Magento 1.6x version.
               a) In this case can i use the migration tool ? If i use the migration tool to migrate the data, this create’s the additional category and website.
               b) I have migrated the data, now i want delta migration again, so which is the best way to migrate the data again in existing M2 DB?              

#2
Profile photo of Mall Staff 184060.00 $tone August 22, 2017
Public

Hi there,

I have used 2.0.4 pro version for migration earlier.

Yes, so that is the root of the issues you mentioned.

  1. During the migration, product url get changed to {{base_url}}.html.html , there is extra “.html” appending in product url

That was because there are some new working rules in Magento 2 regarding URL rewrite. To fix that, you can run the following SQL in your Magento 2 database:
//Before running SQL below, please make sure the product’s attribute with code = ‘request_path’ has attribute_id = 120 in your Magento 2’s database.
 

UPDATE catalog_product_entity_varchar SET value = REPLACE(value, '.html', '') WHERE attribute_id = 120;
UPDATE url_rewrite SET request_path = REPLACE(request_path, '.html.html', '.html') WHERE entity_type = 'product';

Once done, please clean Magento 2 cache.
 

Case 1:- If i migrate the magento 1.6x in fresh magento 2.x,
               a) How can i migrate the core_config_data from magento 1.6x to fresh magento 2.x

It’s pity our tool does not support to migrate such data portion at the moment.

Case 2:-  I mentioned in my previous question that i have migrated my data using 2.0.4 pro version, now i need to update the data in existing M2 DB from Magento 1.6x version.
               a) In this case can i use the migration tool ? If i use the migration tool to migrate the data, this create’s the additional category and website.
               b) I have migrated the data, now i want delta migration again, so which is the best way to migrate the data again in existing M2 DB?              

Do you have a backup of your Magento 2 instance with database migrated using our tool ver 2.0.4? If yes, you should do steps as follows:

  • Revert Magento2 instance to the first instance with ver.2.0.4 of our tool
  • Do reset data migration in ver2.0.4 of our tool.
  • Once done, upgrade our migration tool to the latest ver3.0.9.
  • Start data migration again with ver3.0.4 of our tool (you should select Merge Default Website option in step #2 of our tool)

And then, you will get the latest data from your Magento1’s database in Magento 2.
Regards,
Mall.
 
 
 

#3
Profile photo of Stephen Kidwell 210.00 $tone August 23, 2017
Public

Do you have a backup of your Magento 2 instance with database migrated using our tool ver 2.0.4? If yes, you should do steps as follows:

I reset the old migrated data and run migration using latest version 3.0.9, still have the visibility issue, all product have blank visibility and blank status.

#4
Profile photo of Mall Staff 184060.00 $tone August 23, 2017
Public

Hi there,

I reset the old migrated data and run migration using latest version 3.0.9, still have the visibility issue, all product have blank visibility and blank status.

So, seem your attributes (visibility and status) has special settings (maybe some settings is not standard as Magento default) in Magento1’s database. I need a closer look to detect the root of that issue. Kindly provide some information as followings:

  • Admin credentials of your Magento 2 instance.
  • SSH credentials and web root path of your magento 2 instance.
  • phpMyadmin credentials of your Magento 1 and Magento 2 databases. (this helps me quick check your databases)

I will check further and reply you more later.
Regards,
Mall.

#5
Profile photo of Stephen Kidwell 210.00 $tone August 30, 2017
Public

Hello,
 
I’m facing another issue while updating the data, My M1 version is 1.6x and M2  version is 2.1.7 and php version is 7.0
PHP Error[8]: Trying to get property of non-object
in file /var/www/html/trident-m2_copy3/pub/ub-tool/protected/controllers/Step5Controller.php at line 810
#0 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/controllers/Step5Controller.php(504): Step5Controller->_migrateCatalogProductOptions()
#1 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/controllers/Step5Controller.php(134): Step5Controller->_migrateCatalogProducts()
#2 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/commands/RunCommand.php(58): Step5Controller->actionRun()
#3 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/commands/RunCommand.php(28): RunCommand->_migrateData()
#4 unknown(0): RunCommand->actionIndex()
#5 /var/www/html/trident-m2_copy3/pub/ub-tool/yii/console/CConsoleCommand.php(172): ReflectionMethod->invokeArgs()
#6 /var/www/html/trident-m2_copy3/pub/ub-tool/yii/console/CConsoleCommandRunner.php(71): RunCommand->run()
#7 /var/www/html/trident-m2_copy3/pub/ub-tool/yii/console/CConsoleApplication.php(92): CConsoleCommandRunner->run()
#8 /var/www/html/trident-m2_copy3/pub/ub-tool/yii/base/CApplication.php(184): CConsoleApplication->processRequest()
#9 /var/www/html/trident-m2_copy3/pub/ub-tool/yii/yiic.php(33): CConsoleApplication->run()
#10 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/ubdatamigration_cli.php(5): require_once()
#11 /var/www/html/trident-m2_copy3/bin/ubdatamigration(4): require_once()
 

#8
Profile photo of Mall Staff 184060.00 $tone August 30, 2017
Public

Hi there,

PHP Error[8]: Trying to get property of non-object
in file /var/www/html/trident-m2_copy3/pub/ub-tool/protected/controllers/Step5Controller.php at line 810
#0 /var/www/html/trident-m2_copy3/pub/ub-tool/protected/controllers/Step5Controller.php(504): Step5Controller->_migrateCatalogProductOptions()

Seem you have deleted some product’s options after the first migration with our tool? Let’s try do steps as followings:
-- Run below SQL statement in your Magento 2 database:

Delete From ub_migrate_map_step_5_product_option Where entity_name = 'catalog_product_option' AND m2_id NOT IN (Select option_id From catalog_product_option);

-- Once done, let’s clean the cache files of our tool by run cli command: rm -r pub/ub-tool/protected/runtime/cache
-- And then, re-run the data migration in the step #5: php -f bin/ubdatamigration run --step=5
And tell me know how it goes.
Regards,
Mall.

#9
Profile photo of ubdev Staff 98230.00 $tone August 31, 2017
Public

Hi Stephen,
This is a strange issue, other users have been migrating their databases successfully, without the log-in issue as you mentioned. Could you please check again if the credentials are correct? 
If the issue still persists, kindly provide us the following info:

  • Specific user’s credentials that has the log-in issue and your M1 url (we also need this account to verify if such user can login M1 site successfully or not)
  • Your site credentials as per our instruction on our reply #5 here

Meanwhile, please help to confirm if other issues we provided workarounds above have been resolved? 
Sincerely,
Ubertheme team
 

#11
Profile photo of Stephen Kidwell 210.00 $tone August 31, 2017
Public

Hello,
 
Mentioned issues not get resolved, so i created my own script to update the catalog product visibility.
Another issue i found:- 
I’m running the update mode but the number of products not get increased, why so ? 
 

#12
Profile photo of Mall Staff 184060.00 $tone August 31, 2017
Public

Hi there,

I’m running the update mode but the number of products not get increased, why so ? 

How did you run with that task? What cli command you are using? Is your new added products has new categories added?
Regards,
Mall.

#13
Profile photo of Stephen Kidwell 210.00 $tone August 31, 2017
Public

Hello
command i’m using to update the products and category is 
php -f bin/ubdatamigration run --step=4 --mode=update
php -f bin/ubdatamigration run --step=5 --mode=update

Is your new added products has new categories added?
no

#14
Profile photo of Mall Staff 184060.00 $tone August 31, 2017
Public

Hi there,

php -f bin/ubdatamigration run --step=4 --mode=update
php -f bin/ubdatamigration run --step=5 --mode=update

So, do you have get finished status after run with that cli commands? Did you do reindex your data after run delta migration?
Regards,
Mall.

#15
Profile photo of Stephen Kidwell 210.00 $tone August 31, 2017
Public

Hello,

So, do you have get finished status after run with that cli commands? 

yes

Did you do reindex your data after run delta migration?

yes, still showing the old data, not showing the new order/product
 
 

#16
Profile photo of Stephen Kidwell 210.00 $tone August 31, 2017
Public

Hello,

So, do you have get finished status after run with that cli commands? 

yes

Did you do reindex your data after run delta migration?

yes, still showing the old data, not showing the new order/product
 
 

#17
Profile photo of Mall Staff 184060.00 $tone August 31, 2017
Public

Hi there,

yes, still showing the old data, not showing the new order/product 

That is strange, kindly provide me the admin credentials, ssh credentials and web root folder path of your Magento 2. I will check further and reply you more later.
Regards,
Mall.

#18
Profile photo of Stephen Kidwell 210.00 $tone September 26, 2017
Public

Getting error in step 8 in updated version (3.1.0)
 
Processing in step #8…PHP Error[8]: unserialize(): Error at offset 0 of 331 bytes
in file /var/www/html/trident-m2/pub/ub-tool/protected/models/UBMigrate.php at line 333
#0 /var/www/html/trident-m2/pub/ub-tool/protected/models/UBMigrate.php(333): unserialize()
#1 /var/www/html/trident-m2/pub/ub-tool/protected/controllers/Step8Controller.php(173): UBMigrate->getSettingData()
#2 /var/www/html/trident-m2/pub/ub-tool/protected/commands/RunCommand.php(58): Step8Controller->actionRun()
#3 /var/www/html/trident-m2/pub/ub-tool/protected/commands/RunCommand.php(46): RunCommand->_migrateData()
#4 unknown(0): RunCommand->actionIndex()
#5 /var/www/html/trident-m2/pub/ub-tool/yii-1.1.19/console/CConsoleCommand.php(172): ReflectionMethod->invokeArgs()
#6 /var/www/html/trident-m2/pub/ub-tool/yii-1.1.19/console/CConsoleCommandRunner.php(71): RunCommand->run()
#7 /var/www/html/trident-m2/pub/ub-tool/yii-1.1.19/console/CConsoleApplication.php(92): CConsoleCommandRunner->run()
#8 /var/www/html/trident-m2/pub/ub-tool/yii-1.1.19/base/CApplication.php(185): CConsoleApplication->processRequest()
#9 /var/www/html/trident-m2/pub/ub-tool/yii-1.1.19/yiic.php(33): CConsoleApplication->run()
#10 /var/www/html/trident-m2/pub/ub-tool/protected/ubdatamigration_cli.php(5): require_once()
#11 /var/www/html/trident-m2/bin/ubdatamigration(4): require_once()

#19
Profile photo of Mall Staff 184060.00 $tone September 26, 2017
Public

Hi there,

Processing in step #8…PHP Error[8]: unserialize(): Error at offset 0 of 331 bytes
in file /var/www/html/trident-m2/pub/ub-tool/protected/models/UBMigrate.php at line 333
#0 /var/www/html/trident-m2/pub/ub-tool/protected/models/UBMigrate.php(333): unserialize(

Kindly provide me the admin credentials, ssh credentials and web root folder path of your Magento 2. I will check further and reply you more later.
Regards,
Mall.

#20
Profile photo of Stephen Kidwell 210.00 $tone October 24, 2017
Public

Hi, 
I’m facing a issue in 7th step 

Message: CDbCommand failed to execute the SQL statement: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column ‘lastname’ at row 1. The SQL statement executed was: INSERT INTO `quote_address` (`quote_id`, `updated_at`, `save_in_address_book`, `same_as_billing`, `collect_shipping_rates`, `weight`, `subtotal`, `base_subtotal`, `subtotal_with_discount`, `base_subtotal_with_discount`, `tax_amount`, `base_tax_amount`, `shipping_amount`, `base_shipping_amount`, `discount_amount`, `base_discount_amount`, `grand_total`, `base_grand_total`, `address_id`, `created_at`, `customer_id`, `customer_address_id`, `address_type`, `email`, `firstname`, `lastname`, `street`, `city`, `region`, `region_id`, `postcode`, `country_id`, `telephone`, `shipping_method`, `shipping_description`, `shipping_tax_amount`, `base_shipping_tax_amount`, `applied_taxes`, `shipping_discount_amount`, `base_shipping_discount_amount`, `subtotal_incl_tax`, `shipping_incl_tax`, `base_shipping_incl_tax`, `free_shipping`, `giftcert_amount`, `base_giftcert_amount`) VALUES (:yp0, :yp1, :yp2, :yp3, :yp4, :yp5, :yp6, :yp7, :yp8, :yp9, :yp10, :yp11, :yp12, :yp13, :yp14, :yp15, :yp16, :yp17, :yp18, :yp19, :yp20, :yp21, :yp22, :yp23, :yp24, :yp25, :yp26, :yp27, :yp28, :yp29, :yp30, :yp31, :yp32, :yp33, :yp34, :yp35, :yp36, :yp37, :yp38, :yp39, :yp40, :yp41, :yp42, :yp43, :yp44, :yp45)

 
Ub version is 3.1.0 and magento2 version is 2.1.7 and magento 1 version is 1.6

#21
Profile photo of Mall Staff 184060.00 $tone October 25, 2017
Public

Hi there,

Message: CDbCommand failed to execute the SQL statement: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column ‘lastname’ at row 1. 

You should view this screenshots:
Magento ver.2.1.7 database: http://i.prntscr.com/0zAvAPizRMWxFUkIYfJ_ig.png
Magento ver.2.1.8 database: http://i.prntscr.com/Pj2h-sMiTdmkrWuHghL1Tg.png
So, to solve the issue as you mentioned in the step #7 in ver.3.1.0 of our tool, you should upgrade Magento core to ver2.1.8 or ver.2.1.9
Regards,
Mall.

#22

Please login or Register to Submit Answer

Written By

Comments