Migration stuck on step 5

Hi
We just acquired a licence for UB Migration Tool Pro
We got errors mainly I think using Attribute
As result product are not editable in admin
We do have error on log (system and exception) so it may be the reason
 
When we go through step 3 and 4 seem ok but step 5 is not working
When I go trough command line server is disconnect after some lines
 
Thanks
 

28 answers

Profile photo of Mall Staff 153110.00 $tone September 27, 2020
Public

Hi there,

but step 5 is not working
When I go trough command line server is disconnect after some lines

Let’s continue with data migration in step #5 by run the CLI command:

php -f bin/ubdatamigration run --step=5

And provide me more details of the issue if you see. Also, you can check further in the migration log of our module at path: pub/ub-tool/protected/runtime/ub_data_migration.log
Regards,
Mall.
 
 

#1
Profile photo of Mall Staff 153110.00 $tone September 27, 2020
Public

Hi there,

2020/09/26 23:57:06 [error] [ub_data_migration] CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘station-d-accueil-bose-waver-music-system-iii-silver-32172-3’ for key ‘URL_REWRITE_REQUEST_PATH_STORE_ID’

By the admin credentials you are provided via email, I have checked further in the migration log of our module. And I saw that issue related to data migration in step #5.
To solve that issue you can run the following SQL in your M2 database:

Delete From url_rewrite Where request_path = 'station-d-accueil-bose-waver-music-system-iii-silver-32172' And store_id = 3;

And then, you continue with data migration in step #5. And tell me how it goes.
Regards,
Mall.
 

#2
Profile photo of Mall Staff 153110.00 $tone September 28, 2020
Public

Hi there,

Creating default object from empty value
    in file /home/privile/public_html/pub/ub-tool/protected/controllers/Step5Controller.php at line 689
#0 /home/privile/public_html/pub/ub-tool/protected/controllers/Step5Controller.php(181): Step5Controller->_migrateCatalogProducts()

That issue occurred because you deleted at least one migrated product in M2 after the fist migration. To solve that issue, you can try with the steps below:

1. Run the following SQL queries in your M2 database:

DELETE FROM ub_migrate_map_step_5 WHERE entity_name = 'catalog_product_entity' AND m2_id NOT IN (Select entity_id From catalog_product_entity);
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);
DELETE FROM ub_migrate_map_step_5_product_option WHERE entity_name = 'catalog_product_option_type_value' AND m2_id NOT IN (Select option_type_id From catalog_product_option_type_value);
DELETE FROM ub_migrate_map_step_5_product_option WHERE entity_name = 'catalog_product_option_type_price' AND m2_id NOT IN (Select option_type_price_id From catalog_product_option_type_price);
DELETE FROM ub_migrate_map_step_5_product_option WHERE entity_name = 'catalog_product_bundle_option' AND m2_id NOT IN (Select option_id From catalog_product_bundle_option);
DELETE FROM ub_migrate_map_step_5_product_option WHERE entity_name = 'catalog_product_bundle_selection' AND m2_id NOT IN (Select selection_id From catalog_product_bundle_selection);

2. And then, you run the following command to clean the cache of our module:
rm -rf pub/ub-tool/protected/runtime/cache/
3. Once done, you continue with the data migration in step #5 as normal. 

Regards,
Mall.

#3
Profile photo of jj nini 360.00 $tone September 28, 2020
Public

Hi
I did what you said I run the command until the 1524 products after this terminal show running but is the last product created then nothing (there are 5593 product total)
And more when we open any migrated product in admin we get an error I’m not sure to understand the error
And on front, products not displayed (seem to me that so many is_filtrable attribute cause this but not sure)
Can you tell me how to fix it definitly?

Regards
 

#4
Profile photo of Mall Staff 153110.00 $tone September 29, 2020
Public

Hi there,

I did what you said I run the command until the 1524 products after this terminal show running but is the last product created then nothing (there are 5593 product total)

Did you finish data migration in step #5? Did you see all M1’s products migrated to M2?

And more when we open any migrated product in admin we get an error I’m not sure to understand the error

Please enable full ‘developer’ mode in your M2 site following these steps:

1. Open the SSH terminal, go to the M2 folder and run the CLI command:

php -f bin/magento deploy:mode:set developer

Next, run the command:

cp pub/errors/local.xml.sample pub/errors/local.xml

2. Then open the PHP file at: app/bootstrap.php
and find the code line: 
#error_reporting(E_ALL);

and replace it with:
error_reporting(E_ALL);
 
3. Once done, navigate back to the back-end of your site and check the issue you mentioned. And provide me details of the issue you see there.

Regards,
Mall.
 

#5
Profile photo of jj nini 360.00 $tone September 29, 2020
Public

Hi
I did what you asked
1/ Enable developer mode => ok
2/ replace error_reporting => was already without #
3/ I try to restart but nothing move and we stay at 43% but it seem other products come
Any information on the problem to open product?
Regards
 

#6
Profile photo of Mall Staff 153110.00 $tone September 29, 2020
Public

Hi there,

3/ I try to restart but nothing move and we stay at 43% but it seem other products come
Any information on the problem to open product?

You should wait until you finish the data migration in step #5. Then, you check the issue when viewing a migrated product in the backend and let me how it goes then.

Regards,
Mall.

#7
Profile photo of jj nini 360.00 $tone September 29, 2020
Public

Hi
Listen I’m trying all but now it’s not working
I need your support because I can’t solve the issue for now
Product give errors and only 1691 products are imported and nothing move
Regards

#8
Profile photo of jj nini 360.00 $tone September 29, 2020
Public

hi
we finally succed in migration step 5 ti 7
on Migration step 8 we face
CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ‘AND store_id = 3 AND entity_type = 1 LIMIT 1’ at line 1
Any idea?
Regards

#9
Profile photo of Mall Staff 153110.00 $tone September 30, 2020
Public

Hi there,

on Migration step 8 we face

MariaDB server version for the right syntax to use near ‘AND store_id = 3 AND entity_type = 1 LIMIT 1’ at line 1

Did you see all M1’s products were migrated to M2 after you finished data migration in step #5 of our module?

If yes, that issue occurred because your M1 database had some bad data records in the Product’s review data section. To handle that case, you can try with steps below at your end:

+ Open the PHP file at pub/ub-tool/protected/controllers/Step8Controller.php
and find the code line:

$uniqueCon = "entity_pk_value = {$entityPKValue2} AND store_id = {$storeId2} AND entity_type = {$entityType2}";

and replace it with:

if (!is_numeric($entityPKValue2)) {
continue;
}
$uniqueCon = "entity_pk_value = {$entityPKValue2} AND store_id = {$storeId2} AND entity_type = {$entityType2}";

And then, you continue with data migration in step #8.

If that’s not the case, please provide me information about your instance:

  • ULR and admin credentials of your M2 instance
  • SSH credentials of your M2 instance
  • Let me know the path to the M2 folder

I will help to check further and get back to you then.
PS. Please make sure you mark your reply private or simply switch this ticket to the private mode when sharing your site info. Then, only you and our technical team can access it. 

Regards,
Mall.
 

#10
Profile photo of Mall Staff 153110.00 $tone September 30, 2020
Public

Hi there,

no it miss some products

Yes, I checked your site and saw that your M1 had a total of 5593 products: https://prnt.sc/uqdphw and in the ‘Quick Report’ tab, I saw our migration tool helped to migrate 5385 products: https://prnt.sc/uqdpzd

I checked further into the migration log of our module at pub/ub-tool/protected/runtime/ub_data_migration.log and I saw two other issues related to data migration in step #5:

2020/09/29 07:00:46 [error] [ub_data_migration] CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘sur-lave-vaisselle-integrable-20537-3’ for key ‘URL_REWRITE_REQUEST_PATH_STORE_ID’. The SQL statement executed was: INSERT INTO `url_rewrite`

2020/09/29 13:18:22 [error] [ub_data_migration] CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘sp18-2014-look-pu-140×190-72610-3’ for key ‘URL_REWRITE_REQUEST_PATH_STORE_ID’
2020/09/29 14:29:07 [error] [ub_data_migration] CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘cuisiniere-piano-smeg-cpf9gmbl-multifonction-31084-3’ for key ‘URL_REWRITE_REQUEST_PATH_STORE_ID’. The SQL statement executed was: INSERT INTO `url_rewrite`

I think that is the root of the missing issues on some products above. To solve that issue, you can apply a similar workaround as per my reply #2:

Delete From url_rewrite Where request_path = 'sur-lave-vaisselle-integrable-20537' And store_id = 3;
Delete From url_rewrite Where request_path = 'sp18-2014-look-pu-140x190-72610' And store_id = 3;
Delete From url_rewrite Where request_path = 'cuisiniere-piano-smeg-cpf9gmbl-multifonction-31084' And store_id = 3;

And then, in order to run migration in step #5 from the first record, you continue to run the following SQL query in your M2 database:

UPDATE `ub_migrate_map_step_5` SET `created_time` = '2000-01-01 00:00:00' Where entity_name = 'catalog_product_entity';

After that, run data migration in step #5 using this CLI command:

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

Once done, reindex the data and check the issue you mentioned again.

After you finished data migration in step #5, you can continue to run the data migration in step #8.

Regards,
Mall.
 

#12
Profile photo of jj nini 360.00 $tone September 30, 2020
Public

Hi
I did what you said and after adding some line in ssh I don’t see any in admin and get this error
HP Error[2]: Creating default object from empty value
in file /home/privile/public_html/pub/ub-tool/protected/controllers/Step5Controller.php at line 689
#0 /home/privile/public_html/pub/ub-tool/protected/controllers/Step5Controller.php(181): Step5Controller->_migrateCatalogProducts()
#1 /home/privile/public_html/pub/ub-tool/protected/commands/RunCommand.php(74): Step5Controller->actionRun()
#2 /home/privile/public_html/pub/ub-tool/protected/commands/RunCommand.php(33): RunCommand->_migrateData()
#3 unknown(0): RunCommand->actionIndex()
#4 /home/privile/public_html/pub/ub-tool/yii-1.1.22/console/CConsoleCommand.php(172): ReflectionMethod->invokeArgs()
#5 /home/privile/public_html/pub/ub-tool/yii-1.1.22/console/CConsoleCommandRunner.php(71): RunCommand->run()
#6 /home/privile/public_html/pub/ub-tool/yii-1.1.22/console/CConsoleApplication.php(92): CConsoleCommandRunner->run()
#7 /home/privile/public_html/pub/ub-tool/yii-1.1.22/base/CApplication.php(185): CConsoleApplication->processRequest()
#8 /home/privile/public_html/pub/ub-tool/yii-1.1.22/yiic.php(33): CConsoleApplication->run()
#9 /home/privile/public_html/pub/ub-tool/protected/ubdatamigration_cli.php(5): require_once()
#10 /home/privile/public_html/bin/ubdatamigration(4): require_once()

#13
Profile photo of Mall Staff 153110.00 $tone September 30, 2020
Public

Hi there,

HP Error[2]: Creating default object from empty value
in file /home/privile/public_html/pub/ub-tool/protected/controllers/Step5Controller.php at line 689

That occurred because you did delete at least one migrated product in M2 after the first migration. To solve that issue, you can do steps below:

+ Run the following CLI command:
php -f bin/ubdatamigration clean --step=5
+ And then you continue data migration in step #5 by running the CLI command:
php -f bin/ubdatamigration run --step=5 --mode=update;
 
Regards,
Mall.
 
 

#14
Profile photo of jj nini 360.00 $tone September 30, 2020
Public

Great step 5 finished but still miss some products 5393 instead of 5593
As we don’t have store_id = 3 I remove all lines with store_id = 3 in url_rewrites

now for step 8i still have
[Processing][run] in step #8:
Status: fail
Message: CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ‘AND store_id = 3 AND entity_type = 1 LIMIT 1’ at line 1. The SQL statement executed was: SELECT * FROM `review_entity_summary` `t` WHERE entity_pk_value = AND store_id = 3 AND entity_type = 1 LIMIT 1

#15
Profile photo of Mall Staff 153110.00 $tone September 30, 2020
Public

Hi there,

Pb I still miss 200 products?

That is strange. I checked the log of our module and I saw out tool scans for all 5593 products: http://prntscr.com/uqg1pv
Please try the following steps once more at your end:
1. Run the following SQL in your M2 database:

UPDATE `ub_migrate_map_step_5` SET `created_time` = '2000-01-01 00:00:00' Where entity_name = 'catalog_product_entity';

After that, run data migration in step #5 using this CLI command:

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

Once done, reindex the data and check the issue you mentioned again.

Regards,
Mall.

#17
Profile photo of Mall Staff 153110.00 $tone October 1, 2020
Public

Hi there,

All steps are closed but I have now 5493 miss 100 (after reindex)

That is strange. It seems that your server or database had a special case. Did you see any error message in the latest delta migration in step #5?

Please try with steps below to re-perform data migration in step #5:

1. Run the following SQL query in your M2 database:

UPDATE `ub_migrate_map_step_5` SET `offset` = '0' Where entity_name = 'catalog_product_entity';

2. And then run the CLI command:

php -f bin/ubdatamigration run --step= 5;

3. Once, reindex the data and check the issue you mentioned again.

Regards,
Mall.

#19
Profile photo of ubdev Staff 71680.00 $tone October 1, 2020
Public

Hi there, 
We’re glad that it helped. 
Please move forward with the migration at your end. If you come across any other issue next time, please pause the process and let us know the details of the issue, we will follow up with you then. 
Regards,
Ubertheme team

#21
Profile photo of jj nini 360.00 $tone October 1, 2020
Public

Hi
I see a pb on pricing, product which has special price has special price in price and in advanced pricing we found regular price and special price
but as price = special price the display is not correct
hope I’m clear
 
How to solve this ?
Regards

#22
Profile photo of ubdev Staff 71680.00 $tone October 2, 2020
Public

Hi there, 
 
Please help to explain in more details again and let me know the specific Product SKU’s that had the issue. If possible, please provide the screenshots to illustrate the case you mentioned.
 
Besides, please verify to make sure the price values of your product were migrated correctly. Also, make sure you already reindexed data successfully after the migration.
 
When a product is set with a special price, the special price will be prioritized if it meets the condition of Special Price From & Special Price To datetimes.
 
Regards,
Ubertheme team
 

#23
Profile photo of jj nini 360.00 $tone October 2, 2020
Public

Hi
Sorry if I’m not clear
what I see is on M1 price are filled in price and special price so no pb special price is displayed
on M2 after migration we have special price in price and price in regular price
so product show no discount and display price (which is special price of M1) as if it is normal
if you need I can attach example
And yes indexer was ok

Regards

#24
Profile photo of Mall Staff 153110.00 $tone October 2, 2020
Public

Hi there,

what I see is on M1 price are filled in price and special price so no pb special price is displayed
on M2 after migration we have special price in price and price in regular price
so product show no discount and display price (which is special price of M1) as if it is normal

It seem you referred to the Configurable product’s prices?
 
Please note that M2 removed the pricing for the Configurable products. And the final price of the Configurable product is calculated based on associated product’s prices.

If your M1 configurable product has a price and special price, those price values will be converted to assign to the associated product’s price after being migrated to M2 by our migration.

In case you need further helps from us, please provide me information about your instance:

  • URL and Admin credentials of your M2 instance
  • SSH credentials of your M2 instance
  • Let me know the path to the M2 folder
  • Let me know the product’s SKU which had the issue you mentioned
  • And phpMyadmin URL which allow me to view your M1 and M2 databases

I will help to check further and get back to you then.
PS. Please make sure you mark your reply private or simply switch this ticket to the private mode, then it’s safe to share your site info here. Only you and our technical team can access it. 
Regards,
Mall.
 
 
 

#25
Profile photo of Mall Staff 153110.00 $tone October 2, 2020
Public

Hi there,

Magento 1
https://www.magasins-privilege.fr/enceinte-bluetooth-bose-soundlink-micro-orange
Magento 2
https://privileges.espaceventes.fr/catalog/product/view/id/5064/s/enceinte-bluetooth-bose-soundlink-micro-orange/category/525/

I saw that the product you mentioned (SKU = 0304391) has a final price = $105 in M1 and after being migrated to M2, it has the final price = $105 too.

Also it seem url rewrites not working

You can do steps below so that M2 can re-generate URLs rewrites for you:

1 -- In categories management create a new root category named ‘Temp Root Category’
2 -- Open Stores management, edit the default Store of the default Website and set the ‘Root Category’ form field to the newly added root category ‘Temp Root Category’ and click the Save button.
3 -- Once done, open Stores management once again, edit the default Store of the default Website, and set the Root Category form field to the main root category which you want to publish in the storefront again and click the Save button.

Magento will regenerate categorie and associated product URLs rewrite in this step. It might take some time to complete this task (It depends on the volume of categories and associated products)

And then, re-index the data and clean the Magento cache.
 
Regards,
Mall.
 

#28

Please login or Register to Submit Answer

Written By

Comments