Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Page 1 of 3
Error while upgrading from 1.5.1.0 to 1.6.0.0
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

Hey Folks,

I just tried upgrading from 1.5.1.0 to 1.6.0.0 and here is the error report I get now:

a:5:{i:0;s:216:"Error in file: "/chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Catalog/sql/catalog_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php" - Column "date" does not exists on table "catalog_product_index_website"";i:1;s:1156:"#0 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception('Mage_Core', 'Error in file: ...')
#1 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb('upgrade', '1.4.0.0.44', '1.6.0.0.5')
#2 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb('1.4.0.0.44', '1.6.0.0.5')
#3 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(408): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(336): Mage_Core_Model_App->_initModules()
#6 /chroot/home/mysite/dev.mysiterts.com/html/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#7 /chroot/home/mysite/dev.mysiterts.com/html/index.php(80): Mage::run('', 'store')
#8 {main}"
;s:3:"url";s:1:"/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:7:"default";}

Before I got this error, the install process was taking around 10 minutes. Much longer than the previous versions.

Any ideas how to fix that?

Thanks in advance!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

I think you need to re-index now.

Can you login to admin at all?

If not you can do this from root of your site

./shell php indexer.php reindexall
 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

I re-indexed but no luck :( I think this is a bug in the upgrade script. My 1.5.1 is pretty clean with no customizations.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

Can you login to admin at all?

Can you tell me if you are able to login to admin at all?

Did you reindex via shell?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

Hey Brent! Thanks for trying to help smile

No I can’t login to admin. When I try to access the domain it just sits there for like 15 min and then throws the above error.

And it did reindex successfully in shell :(

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

I don’t have the column in two of my 1.6 installs.

Can you tell me what is in your table?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

here is the screenshot from phpmyadmin

Image Attachments
8-21-2011 10-30-47 AM.jpg
 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

If you re-start the install does it still return the same error?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

I tried the whole process again.

Here is the report I got first time I tried accessing the site (after 15 min of waiting):

a:5:{i:0;s:234:"Error in file: "/chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Customer/sql/customer_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php" - SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0-98' for key 2";i:1;s:1152:"#0 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception('Mage_Core', 'Error in file: ...')
#1 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb('upgrade', '1.4.0.0.14', '1.6.0.0')
#2 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb('1.4.0.0.14', '1.6.0.0')
#3 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(408): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(336): Mage_Core_Model_App->_initModules()
#6 /chroot/home/mysite/dev.mysiterts.com/html/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#7 /chroot/home/mysite/dev.mysiterts.com/html/index.php(80): Mage::run('', 'store')
#8 {main}"
;s:3:"url";s:1:"/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:7:"default";}

Here is the report I got second time I tried accessing the site (after another 15 min of waiting)

a:5:{i:0;s:216:"Error in file: "/chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Catalog/sql/catalog_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php" - Column "date" does not exists on table "catalog_product_index_website"";i:1;s:1156:"#0 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception('Mage_Core', 'Error in file: ...')
#1 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb('upgrade', '1.4.0.0.44', '1.6.0.0.5')
#2 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb('1.4.0.0.44', '1.6.0.0.5')
#3 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(408): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /chroot/home/mysite/dev.mysiterts.com/html/app/code/core/Mage/Core/Model/App.php(336): Mage_Core_Model_App->_initModules()
#6 /chroot/home/mysite/dev.mysiterts.com/html/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#7 /chroot/home/mysite/dev.mysiterts.com/html/index.php(80): Mage::run('', 'store')
#8 {main}"
;s:3:"url";s:1:"/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:7:"default";}

Also, I get the following when I run the upgrade script:

./mage list-installed
No installed packages

./mage list-upgrades
No upgrades available

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

What happens when you try this from the root folder of your site

rm -rf /var/cache session
./mage mage-setup .
./
mage config-set preferred_state stable
./mage list-installed
./mage list-upgrades
./mage install http://connect20.magentocommerce.com/community Mage_All_Latest --force
./shell php indexer.php reindexall
 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 

it completes the process successfully but then when I try to access the site, I get the above errors :(

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

Can you login to admin now?

Do you get this error using the base/default theme?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dbabaev
Sr. Member
 
Total Posts:  83
Joined:  2008-03-29
 
Brent W Peterson - 21 August 2011 06:28 AM

Can you login to admin now?

Do you get this error using the base/default theme?

nope no admin. and yes, default modern skin :(

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

Ok, if you don’t want to get into messy database stuff I would recommend trying your upgrade over again with a fresh version of ver 1.6 and your ver 1.5 database.

Depending on how many orders and how many customers it will take a while to complete.

I think the problem is that the install failed at a point and did not roll back properly so it thinks it needs to insert that record again.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Italo André
Jr. Member
 
Total Posts:  4
Joined:  2010-09-19
 

Hey guys, I just have a similar problem.

As happens to @dbabaev, the install process takes many minutes and then I got an error. I tried upgrading two different stores, but no success in both. Here follows the error:

a:5:{i:0;s:233:\"Error in file: \"/home/italo/www/store_name/app/code/core/Mage/Customer/sql/customer_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php\" - SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry \’0-15\’ for key \’UNQ_BY_CUSTOMER\’\";i:1;s:1016:\"#0 /home/italo/www/store_name/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception(\’Mage_Core\’, \’Error in file: ...\’)
#1 /home/italo/www/store_name/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb(\’upgrade\’, \’1.4.0.0.14\’, \’1.6.0.0\’)
#2 /home/italo/www/store_name/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb(\’1.4.0.0.14\’, \’1.6.0.0\’)
#3 /home/italo/www/store_name/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /home/italo/www/store_name/app/code/core/Mage/Core/Model/App.php(408): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /home/italo/www/store_name/app/code/core/Mage/Core/Model/App.php(336): Mage_Core_Model_App->_initModules()
#6 /home/italo/www/store_name/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#7 /home/italo/www/store_name/index.php(80): Mage::run(\’\’, \’store\’)
#8 {main}\”;s:3:\"url\”;s:50:\"/store_name/index.php/install/wizard/installDb/\”;s:11:\"script_name\”;s:24:\"/store_name/index.php\”;s:4:\"skin\”;s:7:\"default\";}

In another store, I got the same error, but the ‘key’ is different. Here follows the first line, the other lines are just the same as above.

a:5:{i:0;s:222:\"Error in file: \"/home/italo/www/store_name/app/code/core/Mage/Customer/sql/customer_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php\" - SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry \’0\’ for key \’son_id\’\";i:1;s:1016:\"#0 /home/italo/www/store_name/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception(\’Mage_Core\’, \’Error in file: ...\’)

I tried editing some things in the database, but the maximum progress I got was the same error with a different ‘key’.

To upgrade, I’m just doing a ‘new install’ using an ‘old’ database, is that right? I’m using localhost. Both databases are in 1.5.1.0, but I also tried with a 1.4.2.0 backup I have, same problem happens.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Italo André
Jr. Member
 
Total Posts:  4
Joined:  2010-09-19
 

I solved this disabling the unique indexes check.

In the app/etc/config.xml, I changed this

<initStatements>SET NAMES utf8</initStatements>

to this

<initStatements>SET NAMES utf8SET FOREIGN_KEY_CHECKS=0SET UNIQUE_CHECKS=0;</initStatements>

and it worked fine.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 3